New answers tagged editing
According to IMDB (on their "Goofs" page for Dark Knight Rises), comicbook.com, and chaoshour.com, this was an actual mistake, and not just a clumsily attempted time jump/flashback. And I haven't found anywhere that explicitly explains why the scene wouldn't be a continuity error. That said, there are plenty of articles & videos out there dedicated to ...
Just to share one related example: Linda Blair in the Exorcist did not understand what she was doing when she was told to act out the masturbation scene. It was only years later that she figured it out. So it's quite possible that child actors are often not quite aware of the exact nature of the scene they're acting out. Source: Linda Blair herself.
Top 50 recent answers are included