Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / Languages / Managed C++ / September 2004

Tip: Looking for answers? Try searching our database.

Delegating Constructor only supported by native class objects?

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Stephen R. G. Fraser - 11 Sep 2004 23:23 GMT
Are or will delegating constructors (constructors that can call sibling
constructors) be available for ref classes or only for native classes?

The CLI/C++ specs seems to say that it is a native class thing so I just
want to make sure so that I can include/exclude it from the revision of my
book.

(I also can't seem to get it to work for a ref class, if it is supported.)
Carl Daniel [VC++ MVP] - 12 Sep 2004 01:39 GMT
> Are or will delegating constructors (constructors that can call
> sibling constructors) be available for ref classes or only for native
[quoted text clipped - 6 lines]
> (I also can't seem to get it to work for a ref class, if it is
> supported.)

Forwaring constructors aren't supported by the C++ language at all.  There's
currently a proposal to the C++ committee to add that ability in the next
rev of the C++ standard, but that's still 4+ years away.

That said, I haven't looked at what the C++/CLI spec says in this regard.
If they are supported, I'd expect it would be for ref types only, since
they're definitely NOT supported for native types.

-cd
Carl Daniel [VC++ MVP] - 12 Sep 2004 01:42 GMT
> Forwarding constructors aren't supported by the C++ language at all.
> There's currently a proposal to the C++ committee to add that ability
[quoted text clipped - 3 lines]
> regard. If they are supported, I'd expect it would be for ref types
> only, since they're definitely NOT supported for native types.

Indeed, the C++/CLI spec only mentions this feature in the "Future
Directions" section, so I'd say that for Whidbey the answer is clearly "not
supported for any types".

-cd
Brandon Bray [MSFT] - 15 Sep 2004 02:03 GMT
> Indeed, the C++/CLI spec only mentions this feature in the "Future
> Directions" section, so I'd say that for Whidbey the answer is clearly
> "not supported for any types".

That's right. After the C++ standards committee took to designing parts of
the feature, the Visual C++ team backed off of implementing this feature.
Anytime the standards committee starts working on a design, it's very risky
for us to implement it is a release product.

Signature

Brandon Bray, Visual C++ Compiler         http://blogs.msdn.com/branbray/
Bugs? Suggestions? Feedback?   http://msdn.microsoft.com/productfeedback/


Rate this thread:







Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.