Should I avoid sitting on top tube on my carbon bike?
I have never had or heard of a problem.
Over at www.velominati.com, one of the rules is

Rule #80 // Always be Casually Deliberate.
Waiting for others pre-ride or at the start line pre-race, you must be tranquilo, resting on your top tube thusly. This may be extended to any time one is aboard the bike, but not riding it, such as at stop lights.

While some of what they say is tongue in cheek, this one is not. Most people I know do it, and have done for years.