---
title: "Meaning & Key Takeaway of: Destructors for virtual base classes are…"
description: "\"Destructors for virtual base classes are executed in the reverse order of their appearance in a depth-first left-to-right traversal of the directed acy..."
image: "https://sms4smile.com/quotes/i/304/bjarne-stroustrup-11774_appearance_destructors-for-virtual-base-classes-are_2160845.jpg"
---

#  Destructors for virtual base classes are executed in the…

![“Destructors for virtual base classes are executed in the reverse order of their appearance in a depth-first left-to-right traversal of the directed acyclic graph of base classes.” quote by Bjarne Stroustrup](https://sms4smile.com/quotes/i/304/bjarne-stroustrup-11774_appearance_destructors-for-virtual-base-classes-are_2160845.jpg)   [Download](https://sms4smile.com/quotes/i/304/bjarne-stroustrup-11774_appearance_destructors-for-virtual-base-classes-are_2160845.jpg) [Open image](https://sms4smile.com/quotes/i/304/bjarne-stroustrup-11774_appearance_destructors-for-virtual-base-classes-are_2160845.jpg)

> “Destructors for virtual base classes are executed in the reverse order of their appearance in a depth-first left-to-right traversal of the directed acyclic graph of base classes.”

[Bjarne Stroustrup](https://sms4smile.com/quotes/author/bjarne-stroustrup/)

## About This Quote

This interpretation was drafted with AI assistance. It is one reading of the quote, not the author's own explanation.

Destructors for virtual bases run in reverse order of a depth‑first left‑to‑right traversal of the inheritance graph.

**In simple terms:** Virtual base destructors run opposite to their appearance order.

Key Takeaway

Understand and respect the order when designing class hierarchies.

Themes

C++ inheritance resource management

Mood

technical analytical

Type

educational reference

When to use this quote

- Implementing polymorphic libraries
- debugging destructor crashes
- ensuring proper resource release

Key Concepts

Object‑oriented design deterministic cleanup

Questions to Reflect On

- How does this order affect resource deallocation?
- When might you need to override this behavior?

A Different Perspective

If multiple inheritance is deep, the order can be hard to predict, leading to subtle bugs.

★ ★ ★ ★ ★   No ratings yet

[Class](https://sms4smile.com/quotes/about/class/) [Depth](https://sms4smile.com/quotes/about/depth/) [Order](https://sms4smile.com/quotes/about/order/) [Technology](https://sms4smile.com/quotes/about/technology/)

## Related quotes

> [“Then wine me, dine me and sixty-nine me,” she growled. “Feel free to reverse the order.”](https://sms4smile.com/quotes/susan-gabriel/then-wine-me-dine-me-and-sixty-nine-me-she-growled-feel-free-to/)

Susan Gabriel

> [“Taking a sip, the Count reviewed the menu in reverse order as was his habit, having learned from experience that giving consideration to appetizers…](https://sms4smile.com/quotes/amor-towles/taking-a-sip-the-count-reviewed-the-menu-in-reverse-order-as-was-his/)

[Amor Towles](https://sms4smile.com/quotes/author/amor-towles/)

> [Sometimes to speak as a woman is to cry, and to speak from our emotional, intuitive knowing, as opposed to graphs and charts and…](https://sms4smile.com/quotes/elizabeth-lesser/sometimes-to-speak-as-a-woman-is-to-cry-and-to-speak-from-our/)

[Elizabeth Lesser](https://sms4smile.com/quotes/author/elizabeth-lesser/)

> [Think about spam filters; if email didnt come from someone that someone you know knows, thats an important signal, and one we could embed…](https://sms4smile.com/quotes/clay-shirky/think-about-spam-filters-if-email-didnt-come-from-someone-that/)

[Clay Shirky](https://sms4smile.com/quotes/author/clay-shirky/)

> [Every dance is a kind of fever chart, a graph of the heart. The instrument through which the dance speaks is also the instrument…](https://sms4smile.com/quotes/martha-graham/every-dance-is-a-kind-of-fever-chart-a-graph-of-the-heart-the/)

[Martha Graham](https://sms4smile.com/quotes/author/martha-graham/)

> [In sound design programs now, you can literally sculpt the sound on visual graphs. Sometimes the visual programs are even more interesting than the…](https://sms4smile.com/quotes/doug-aitken/in-sound-design-programs-now-you-can-literally-sculpt-the-sound-on/)

[Doug Aitken](https://sms4smile.com/quotes/author/doug-aitken/)

> [The trouble is that the hockey stick graph become an icon and deniers reckoned if they could smash the icon, the whole concept of…](https://sms4smile.com/quotes/michael-e-mann/the-trouble-is-that-the-hockey-stick-graph-become-an-icon-and-deniers/)

[Michael E. Mann](https://sms4smile.com/quotes/author/michael-e-mann/)

> [But there are certain books I would never put on a Kindle because you want to be able to look at graphs and photos…](https://sms4smile.com/quotes/lisa-see/but-there-are-certain-books-i-would-never-put-on-a-kindle-because-you/)

[Lisa See](https://sms4smile.com/quotes/author/lisa-see/)

> [People will come to your site because you have good compelling content. You need to hit it from all angles: blog posts, articles, graphs,…](https://sms4smile.com/quotes/chris-bennett/people-will-come-to-your-site-because-you-have-good-compelling/)

Chris Bennett

> [Facebook isn't helping you make new connections, Facebook doesn't develop new relationships, Facebook is just trying to be the most accurate model of your…](https://sms4smile.com/quotes/sean-parker/facebook-isn-t-helping-you-make-new-connections-facebook-doesn-t/)

[Sean Parker](https://sms4smile.com/quotes/author/sean-parker/)

> [The company that creates one global social graph will be very important going forward. It will be Facebook, with maybe 2-3 local social networks…](https://sms4smile.com/quotes/yuri-milner/the-company-that-creates-one-global-social-graph-will-be-very/)

[Yuri Milner](https://sms4smile.com/quotes/author/yuri-milner/)

> [If Facebook gets your entire social graph, you don't necessarily want to share everything with your entire social graph. You might wanna parse that…](https://sms4smile.com/quotes/ashton-kutcher/if-facebook-gets-your-entire-social-graph-you-don-t-necessarily-want/)

[Ashton Kutcher](https://sms4smile.com/quotes/author/ashton-kutcher/)

> [One day, I went to a soba restaurant outside town, and while I was waiting for the zarusoba I opened an old graph magazine.…](https://sms4smile.com/quotes/osamu-dazai/one-day-i-went-to-a-soba-restaurant-outside-town-and-while-i-was/)

[Osamu Dazai](https://sms4smile.com/quotes/author/osamu-dazai/)

> [When I first began examining the global-warming scare, I found nothing more puzzling than the way officially approved scientists kept on being shown to…](https://sms4smile.com/quotes/christopher-booker/when-i-first-began-examining-the-global-warming-scare-i-found-nothing/)

[Christopher Booker](https://sms4smile.com/quotes/author/christopher-booker/)

> [What do these graphs look like?! -awkward silence- uh.. Lines?](https://sms4smile.com/quotes/hannah-bowns/what-do-these-graphs-look-like-awkward-silence-uh-lines/)

Hannah Bowns

## More by Bjarne Stroustrup

> [Always think about how a piece of code should be used: good interfaces are the essence of good code. You can hide all kinds…](https://sms4smile.com/quotes/bjarne-stroustrup/always-think-about-how-a-piece-of-code-should-be-used-good-interfaces/)

[Bjarne Stroustrup](https://sms4smile.com/quotes/author/bjarne-stroustrup/)

> [Any verbose and tedious solution is error-prone because programmers get bored.](https://sms4smile.com/quotes/bjarne-stroustrup/any-verbose-and-tedious-solution-is-error-prone-because-programmers/)

[Bjarne Stroustrup](https://sms4smile.com/quotes/author/bjarne-stroustrup/)

> [“There are only two kinds of languages: the ones people complain about and the ones nobody uses.”](https://sms4smile.com/quotes/bjarne-stroustrup/there-are-only-two-kinds-of-languages-the-ones-people-complain-about/)

[Bjarne Stroustrup](https://sms4smile.com/quotes/author/bjarne-stroustrup/)

> [Nobody should call themselves a professional if they only knew one language.](https://sms4smile.com/quotes/bjarne-stroustrup/nobody-should-call-themselves-a-professional-if-they-only-knew-one/)

[Bjarne Stroustrup](https://sms4smile.com/quotes/author/bjarne-stroustrup/)

> [It's easy to win forgiveness for being wrong; being right is what gets you into real trouble.](https://sms4smile.com/quotes/bjarne-stroustrup/it-s-easy-to-win-forgiveness-for-being-wrong-being-right-is-what-gets/)

[Bjarne Stroustrup](https://sms4smile.com/quotes/author/bjarne-stroustrup/)

> [Some software is actually pretty good, by any standard. Think of the Mars Rovers, Google, and the Human Genome Project. Now, that's quality software!](https://sms4smile.com/quotes/bjarne-stroustrup/some-software-is-actually-pretty-good-by-any-standard-think-of-the/)

[Bjarne Stroustrup](https://sms4smile.com/quotes/author/bjarne-stroustrup/)

> [C makes it easy to shoot yourself in the foot; C++ makes it harder, but when you do, it blows away your whole leg.](https://sms4smile.com/quotes/bjarne-stroustrup/c-makes-it-easy-to-shoot-yourself-in-the-foot-c-makes-it-harder-but/)

[Bjarne Stroustrup](https://sms4smile.com/quotes/author/bjarne-stroustrup/)

> [I assume that a sufficiently skilled will be able to do anything not explicitly forbidden by the hardware.](https://sms4smile.com/quotes/bjarne-stroustrup/i-assume-that-a-sufficiently-skilled-will-be-able-to-do-anything-not/)

[Bjarne Stroustrup](https://sms4smile.com/quotes/author/bjarne-stroustrup/)

> [I like doing research that has an impact. If I went to a company to make what they call 'real money,' I'd be just…](https://sms4smile.com/quotes/bjarne-stroustrup/i-like-doing-research-that-has-an-impact-if-i-went-to-a-company-to/)

[Bjarne Stroustrup](https://sms4smile.com/quotes/author/bjarne-stroustrup/)

> [I would encourage nonproprietary standards for tools and libraries](https://sms4smile.com/quotes/bjarne-stroustrup/i-would-encourage-nonproprietary-standards-for-tools-and-libraries/)

[Bjarne Stroustrup](https://sms4smile.com/quotes/author/bjarne-stroustrup/)

> [This evolution may compromise Java's claim of being simpler than C++, but my guess is that the effort will make Java a better language…](https://sms4smile.com/quotes/bjarne-stroustrup/this-evolution-may-compromise-java-s-claim-of-being-simpler-than-c/)

[Bjarne Stroustrup](https://sms4smile.com/quotes/author/bjarne-stroustrup/)

> [Clearly, I reject the view that there is one way that is right for everyone and for every problem](https://sms4smile.com/quotes/bjarne-stroustrup/clearly-i-reject-the-view-that-there-is-one-way-that-is-right-for/)

[Bjarne Stroustrup](https://sms4smile.com/quotes/author/bjarne-stroustrup/)

> [There is no one "root of all evil" in software development. Design is hard in many ways. People tend to underestimate the intellectual and…](https://sms4smile.com/quotes/bjarne-stroustrup/there-is-no-one-root-of-all-evil-in-software-development-design-is/)

[Bjarne Stroustrup](https://sms4smile.com/quotes/author/bjarne-stroustrup/)

> [However, when Java is promoted as the sole programming language, its flaws and limitations become serious.](https://sms4smile.com/quotes/bjarne-stroustrup/however-when-java-is-promoted-as-the-sole-programming-language-its/)

[Bjarne Stroustrup](https://sms4smile.com/quotes/author/bjarne-stroustrup/)

> [C++ is designed to allow you to express ideas, but if you don't have ideas or don't have any clue about how to express…](https://sms4smile.com/quotes/bjarne-stroustrup/c-is-designed-to-allow-you-to-express-ideas-but-if-you-don-t-have/)

[Bjarne Stroustrup](https://sms4smile.com/quotes/author/bjarne-stroustrup/)

[Explore all 58 Bjarne Stroustrup quotes ](https://sms4smile.com/quotes/author/bjarne-stroustrup/)

## More Appearance quotes

> [Your looks don't make you pretty, it's the person inside who makes you pretty!](https://sms4smile.com/quotes/aaron-chan/your-looks-don-t-make-you-pretty-it-s-the-person-inside-who-makes-you/)

[Aaron Chan](https://sms4smile.com/quotes/author/aaron-chan/)

> [I just worried about my weight. Worried about my appearance and thought I wan't pretty enough to be a pop star. It was very…](https://sms4smile.com/quotes/judith-durham/i-just-worried-about-my-weight-worried-about-my-appearance-and/)

[Judith Durham](https://sms4smile.com/quotes/author/judith-durham/)

> [The essence of worldliness is exclusion of God.](https://sms4smile.com/quotes/henry-jacobsen/the-essence-of-worldliness-is-exclusion-of-god/)

[Henry Jacobsen](https://sms4smile.com/quotes/author/henry-jacobsen/)

> [We must, however, note that what are usually called the high religions made their appearance within about twenty-five hundred years - most of them…](https://sms4smile.com/quotes/kenneth-scott-latourette/we-must-however-note-that-what-are-usually-called-the-high-religions/)

[Kenneth Scott Latourette](https://sms4smile.com/quotes/author/kenneth-scott-latourette/)

> [First impressions are often the truest, as we find (not infrequently) to our cost, when we have been wheedled out of them by plausible…](https://sms4smile.com/quotes/william-hazlitt/first-impressions-are-often-the-truest-as-we-find-not-infrequently-to/)

[William Hazlitt](https://sms4smile.com/quotes/author/william-hazlitt/)

> [The turning points of lives are not the great moments. The real crises are often concealed in occurrences so trivial in appearance that they…](https://sms4smile.com/quotes/george-washington/the-turning-points-of-lives-are-not-the-great-moments-the-real-crises/)

[George Washington](https://sms4smile.com/quotes/author/george-washington/)

> [You can have a nice body, dress with the latest fashion. But if you don't have self-confidence sweetheart, forget about looking sexy, you can't…](https://sms4smile.com/quotes/glen-rambharack/you-can-have-a-nice-body-dress-with-the-latest-fashion-but-if-you-don/)

[Glen Rambharack](https://sms4smile.com/quotes/author/glen-rambharack/)

> [I cannot be convinced that great artists are moralists. Art is first appearances, then meaning.](https://sms4smile.com/quotes/camille-paglia/i-cannot-be-convinced-that-great-artists-are-moralists-art-is-first/)

[Camille Paglia](https://sms4smile.com/quotes/author/camille-paglia/)

> [So may the outward shows be least themselves; The world is still deceived with ornament.](https://sms4smile.com/quotes/anonymous/so-may-the-outward-shows-be-least-themselves-the-world-is-still/)

[Anonymous](https://sms4smile.com/quotes/author/anonymous/)

> [We are one of many appearances of the thing called Life; we are not its perfect image, for it has no perfect image except…](https://sms4smile.com/quotes/loren-eiseley/we-are-one-of-many-appearances-of-the-thing-called-life-we-are-not/)

[Loren Eiseley](https://sms4smile.com/quotes/author/loren-eiseley/)

> [I'm OK with my appearance. I have made my peace with it after a long and frankly exhausting battle.](https://sms4smile.com/quotes/sue-perkins/i-m-ok-with-my-appearance-i-have-made-my-peace-with-it-after-a-long/)

[Sue Perkins](https://sms4smile.com/quotes/author/sue-perkins/)

> [There is no society or conversation to be kept up in the world without good-nature, or something which must bear its appearance and supply…](https://sms4smile.com/quotes/joseph-addison/there-is-no-society-or-conversation-to-be-kept-up-in-the-world/)

[Joseph Addison](https://sms4smile.com/quotes/author/joseph-addison/)

> [Appearance records are pretty special. Mine means a lot to me, not only because I love stats, but because it shows that I am…](https://sms4smile.com/quotes/david-james/appearance-records-are-pretty-special-mine-means-a-lot-to-me-not-only/)

[David James](https://sms4smile.com/quotes/author/david-james/)

> [Every man would fall in love with their voice, their lovely appearance, but no man would ever get past that. They'd never really know…](https://sms4smile.com/quotes/amanda-hocking/every-man-would-fall-in-love-with-their-voice-their-lovely-appearance/)

[Amanda Hocking](https://sms4smile.com/quotes/author/amanda-hocking/)

> [I already know what things look like - I don't want description. People believe in appearances, and I don't believe in appearances at all.](https://sms4smile.com/quotes/duane-michals/i-already-know-what-things-look-like-i-don-t-want-description-people/)

[Duane Michals](https://sms4smile.com/quotes/author/duane-michals/)

Browse all 2,446 Appearance quotes

```json
{
    "@context": "https://schema.org",
    "@graph": [
        {
            "@type": "Quotation",
            "text": "Destructors for virtual base classes are executed in the reverse order of their appearance in a depth-first left-to-right traversal of the directed acyclic graph of base classes.",
            "creator": {
                "@type": "Person",
                "name": "Bjarne Stroustrup"
            },
            "isPartOf": {
                "@id": "https://sms4smile.com/quotes/#website"
            },
            "url": "https://sms4smile.com/quotes/bjarne-stroustrup/destructors-for-virtual-base-classes-are-executed-in-the-reverse/",
            "about": {
                "@type": "Thing",
                "name": "Appearance"
            },
            "@id": "https://sms4smile.com/quotes/bjarne-stroustrup/destructors-for-virtual-base-classes-are-executed-in-the-reverse/#quotation",
            "image": {
                "@type": "ImageObject",
                "@id": "https://sms4smile.com/quotes/i/304/bjarne-stroustrup-11774_appearance_destructors-for-virtual-base-classes-are_2160845.jpg",
                "contentUrl": "https://sms4smile.com/quotes/i/304/bjarne-stroustrup-11774_appearance_destructors-for-virtual-base-classes-are_2160845.jpg",
                "url": "https://sms4smile.com/quotes/i/304/bjarne-stroustrup-11774_appearance_destructors-for-virtual-base-classes-are_2160845.jpg",
                "width": 1080,
                "height": 1080,
                "caption": "“Destructors for virtual base classes are executed in the reverse order of their appearance in a depth-first…” — Bjarne Stroustrup",
                "creditText": "SMS4Smile Quotes",
                "creator": {
                    "@id": "https://sms4smile.com/quotes/#organization"
                }
            }
        },
        {
            "@type": "BreadcrumbList",
            "itemListElement": [
                {
                    "@type": "ListItem",
                    "position": 1,
                    "name": "Home",
                    "item": "https://sms4smile.com/"
                },
                {
                    "@type": "ListItem",
                    "position": 2,
                    "name": "Quotes",
                    "item": "https://sms4smile.com/quotes/"
                },
                {
                    "@type": "ListItem",
                    "position": 3,
                    "name": "Bjarne Stroustrup",
                    "item": "https://sms4smile.com/quotes/author/bjarne-stroustrup/"
                },
                {
                    "@type": "ListItem",
                    "position": 4,
                    "name": "Destructors for virtual base classes are...",
                    "item": "https://sms4smile.com/quotes/bjarne-stroustrup/destructors-for-virtual-base-classes-are-executed-in-the-reverse/"
                }
            ],
            "@id": "https://sms4smile.com/quotes/bjarne-stroustrup/destructors-for-virtual-base-classes-are-executed-in-the-reverse/#breadcrumb"
        },
        {
            "@type": "WebSite",
            "@id": "https://sms4smile.com/quotes/#website",
            "name": "SMS4Smile Quotes",
            "url": "https://sms4smile.com/quotes/",
            "publisher": {
                "@id": "https://sms4smile.com/quotes/#organization"
            }
        },
        {
            "@type": "Organization",
            "@id": "https://sms4smile.com/quotes/#organization",
            "name": "SMS4Smile Quotes",
            "url": "https://sms4smile.com/quotes/",
            "logo": {
                "@type": "ImageObject",
                "url": "https://sms4smile.com/quotes/wp-content/themes/sq/assets/icons/icon-512.png",
                "width": 512,
                "height": 512
            }
        }
    ]
}
```
