That would depend on the size of your compost pile in relation to the amount of lemons or any sort of citrus.
I've read that having a small worm composter is not a good mix for more than an occasional citrus peel, or that something small in size where its fed occasional kitchen scraps is not a good mixture due to the antibacterial properties of the citrus.
However, those things mold the same as anything else, and I've always tossed them in to my out door compost bins with out any negative effect. They break down just the same as anything else. The only time I've seen an acid cause problems was when I dumped several quarts of old home canned pickles in to the compost pile, the vinegar seemed to stunt it for a couple of weeks. Even now, with the kind of margarita and mojhito fan that I am and the copious amounts of limes I go though, they break down quicker than anything in my pile.