fst@mcgp1.UUCP (Skip Tavakkolian) (10/11/88)
I need an explanation on how to verbalize (visualize) use of a constructor as an operand to new operator. In section 5.4.3 of ``the C++ programming language'' [B. Stroustrup, reprint July, 1987] you'll find the following: class set { struct setmem { int mem; setmem *next; setmem(int m, setmem *n) { mem=m; next=n; } }; setmem *first; public: set() { first = 0; } insert(int m) { first = new setmem(m, first); } // ... }; There is no apparent return value from ``setmem'' constructor (i.e. setmem(int, setmem*) ). Where does the operand for new come from. I believe this is correct, I am just trying to visualize how the compiler interprets this. Many Thanks -- Fariborz ``Skip'' Tavakkolian UUCP ...!uw-beaver!tikal!mcgp1!fst UNIX is a registered trademark of AT&T