You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to
Am I right in thinking that a constant object of a class must have an accessible user provided constructor if it is not list-initialised?
Fraser.
Maxim Yegorushkin
unread,
Nov 28, 2008, 12:15:06 PM11/28/08
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to
On Nov 28, 4:25 pm, "Fraser Ross" <z...@zzzzzz.com> wrote: > Am I right in thinking that a constant object of a class must have an > accessible user provided constructor if it is not list-initialised?
You are quite right.
-- Max
Fraser Ross
unread,
Nov 29, 2008, 11:28:12 AM11/29/08
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to
>> Am I right in thinking that a constant object of a class must have an >> accessible user provided constructor if it is not list-initialised?
>You are quite right.
class B { };
class A { B b_; public: A() {} };
B const b={}; A const a;
void func() { B const b={}; A const a; }
Borlands compiler confirms my deductions with the above code.