IT Community - Software Programming, Web Development and Technical Support

Conversion constructor

This is a discussion on Conversion constructor within the C and C++ Programming forums, part of the Software Development category; Conversion constructor A constructor that accepts one argument of a different type. The compiler uses this idiom as one way ...


Go Back   IT Community - Software Programming, Web Development and Technical Support > Software Development > C and C++ Programming

Register FAQ Members List Calendar Mark Forums Read
  #1 (permalink)  
Old 09-21-2007, 03:36 AM
vijayanand vijayanand is offline
D-Web Analyst
 
Join Date: Feb 2007
Posts: 293
vijayanand is on a distinguished road
Default Conversion constructor

Conversion constructor

A constructor that accepts one argument of a different type.
The compiler uses this idiom as one way to infer conversion rules for your class. A constructor with more than one argument and with default argument values can be interpreted by the compiler as a conversion constructor when the compiler is looking for an object of your constructor's type and sees an object of the type of the constructor's first argument.
__________________

J.Vijayanand
Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Sponsored Links
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
conversion from ogg to mp3 JSureshkumar Operating Systems 33 04-10-2008 09:44 PM
Conversion error Kirubhananth ASP and ASP.NET Programming 4 03-12-2008 10:03 PM
Copy constructor and an overloaded assignment operator vijayanand C and C++ Programming 0 09-21-2007 03:37 AM
Embedded Currency Conversion Alkazar HTML, CSS and Javascript Coding Techniques 1 08-27-2007 07:57 AM
How to do a type conversion in VC++ .NET? bluesky C and C++ Programming 2 08-10-2007 05:38 AM


All times are GMT -7. The time now is 09:33 PM.


Copyright ©2004 - 2007, DiscussWeb. All Rights Reserved.

SEO by vBSEO 3.0.0