I got locked in my local cemetery not that long ago. Went for a walk around it, by the time I got back to the gate (shortly before it was due to start getting dark) found it had been padlocked.
Now, for some reason, this cemetery (which is pretty large and is about 200 years old, with some pretty elaborate family tombs - looking it up, it seems there have been about 1/4 of a million people buried in there in total) has a _really_ high wall all round it (as in, for most of it it's maybe 25 feet high). Not sure if that's because they were worried about outsiders getting in to rob the tombs, or if they were worried about those within getting out.
Eventually, walking all the way round the perimeter, I found a section (behind some bushes) where the wall was lower, and there was a convenient fence running next to the wall that I could climb on to to then haul myself over the wall (just as it was getting dark). Was kind of panicked for a bit there.