Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > C++ > Why can't a base class subobject be copied to and from an array of char

Reply
Thread Tools

Why can't a base class subobject be copied to and from an array of char

 
 
Fraser Ross
Guest
Posts: n/a
 
      04-08-2009
At 3.9/2 in the standard I can understand that a base class subobject
might have size 0 but is that the reason for it being an exception? If
it is then why does the standard not make this clearer? Is there any
other reason? A reference to a base class can be obtained with
static_cast. I don't see a problem with getting a pointer or reference
to a base class.

Fraser.


 
Reply With Quote
 
 
 
Reply

Thread Tools

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

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
findcontrol("PlaceHolderPrice") why why why why why why why why why why why Mr. SweatyFinger ASP .Net 2 12-02-2006 03:46 PM
(const char *cp) and (char *p) are consistent type, (const char **cpp) and (char **pp) are not consistent lovecreatesbeauty C Programming 1 05-09-2006 08:01 AM
Problem- strcat with char and char indexed from char array aldonnelley@gmail.com C++ 3 04-20-2006 07:32 AM
/usr/bin/ld: ../../dist/lib/libjsdombase_s.a(BlockGrouper.o)(.text+0x98): unresolvable relocation against symbol `std::basic_ostream<char, std::char_traits<char> >& std::endl<char, std::char_traits<char> >(std::basic_ostre silverburgh.meryl@gmail.com C++ 3 03-09-2006 12:14 AM
const base subobject Dave C++ 1 04-05-2004 09:20 PM



Advertisments