Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9282169
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 18, 20262026-06-18T18:18:24+00:00 2026-06-18T18:18:24+00:00

I have a tricky C++ question: When you have a constructor initialization list with

  • 0

I have a tricky C++ question: When you have a constructor initialization list with delegated constructors, what is the list execution order?

There exist two conflicting standard rules here:
1.) The constructor initialization list gets executed NOT by the list order but by the declaration order of the items.
2.) Delegated constructors in the constructor initialization list always get called before the “mother constructor” is executed.

Which rule is superior? (since a constructor is a class item too)
Why this is important: assume the delegated constructor re-inits an item already initialized by the “mother constructor” or vice versa.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-18T18:18:26+00:00Added an answer on June 18, 2026 at 6:18 pm

    §12.6.2/6 says

    If a mem-initializer-id designates the constructor’s class,
    it shall be the only mem-initializer… Once the target constructor returns, the body of the
    delegating constructor is executed.

    So there’s no conflict, since you can’t initialise anything before you delegate a constructor. Delegating a constructor simply calls that constructor, the target constructor’s initialiser list is run, the target constructor runs, and then the principal constructor runs.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a tricky question regarding shallow serialization of List of objects my entities
I have what I think is a tricky question, but hopefully someone on here
here's a tricky question... I have default styled input fields (no css added, just
I have a tricky question regarding to what i'm trying to do. I have
This is a tricky question to explain, but basically I have an app with
maybe its a tricky question but anyway: I have a facebook application running on
This sounds like a tricky question... let me ellaborate... I have a treeView. When
I have a really tricky task to do: there is an existing web project
I have a rather tricky question with a looong story, hopefully I can convey
I have a tricky question. My java program is doing in a loop such

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.