Part of growing up is being able to figure out what is right and what is wrong, especially if there will be serious consequences for not doing what is right. For Jem, this means turning in the runaway Dill, who is hiding under Scout’s bed. Dill feels at home in Maycomb because of the unique friendships he has with Scout and Jem, and he also admires Atticus for being the type of father he never had. Poor Dill feels unloved and neglected by his own family, who doesn’t seem to have time for him. Maycomb is a refuge for Dill where he feels wanted and appreciated by his friends.
Jem telling Atticus about Dill running away and hiding breaks the code of childhood where you don’t “rat” on one another. For example, Dill covers for Jem when Jem loses his pants to the Radley wire fence, and it is an unstated rule of childhood to not tell on each other even if you have to lie. However, Jem understands that Dill’s disappearance is dangerous, and Dill’s family will probably be in a panic over where Dill is. Jem shows that he is growing up and is learning to make adult decisions that supersede any kind of childhood pact that he once made.
In Chapter 14 of Harper Lee's novel To Kill a Mockingbird, Dill has run away from home and taken refuge under Scout's bed, where he hid for two hours. Jem, clearly understanding the gravity of the situation, insists that Dill's mother ought to informed of her son's whereabouts despite Dill's obvious pleasure in the thought of people back home searching for him. It is then that Scout comments on Jem's decision to inform Atticus of this new development:
Dill’s eyes flickered at Jem, and Jem looked at the floor. Then he rose and broke
the remaining code of our childhood. He went out of the room and down the hall.
“Atticus,” his voice was distant, “can you come here a minute, sir?”
Scout is aghast that her brother would violate this childhood 'code of conduct' that precluded the provision of sensitive information to adults, especially information regarding their own conduct and that of Dill, their closest friend. The episode, however, serves to illuminate the degree to which Jem has matured emotionally and is ready to make that transition towards adulthood.
Jem breaks the code of childhood by acting responsibly. Dill had run away from home, and was hiding under Scout's bed. She goes to get Jem and when he discovers Dill, he knows that it is not something he can keep a secret.He shocks Scout by going and telling his father what had happened.
This is a another example of Jem's maturity. Scout did not think to run and get her father, but Jem knew it was what he had to do.
Dill ran away because he felt he was not getting enough attention, and Jem realizes that she would nonetheless be worried sick. He has grown past the childish ideas of running away from home to solve you problems.