home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #26 / NN_1992_26.iso / spool / comp / std / cplus / 1526 < prev    next >
Encoding:
Text File  |  1992-11-09  |  1.3 KB  |  36 lines

  1. Newsgroups: comp.std.c++
  2. Path: sparky!uunet!munnari.oz.au!metro!extro.ucc.su.OZ.AU!maxtal
  3. From: maxtal@extro.ucc.su.OZ.AU (John MAX Skaller)
  4. Subject: Re: Unitialized dynamic reference
  5. Message-ID: <1992Nov10.013115.29919@ucc.su.OZ.AU>
  6. Sender: news@ucc.su.OZ.AU
  7. Nntp-Posting-Host: extro.ucc.su.oz.au
  8. Organization: MAXTAL P/L C/- University Computing Centre, Sydney
  9. References: <1dessbINNn1b@darkstar.UCSC.EDU>
  10. Date: Tue, 10 Nov 1992 01:31:15 GMT
  11. Lines: 23
  12.  
  13. In article <1dessbINNn1b@darkstar.UCSC.EDU> daniel@cse.ucsc.edu (Daniel R. Edelson) writes:
  14. >
  15. >The draft standard has the following to say about references:
  16. >
  17. >``The declaraion of a reference must contain an initializer except
  18. >when the declaration contains an explicit extern specifier, is a
  19. >class member, declaration within a class declaration, or is the
  20. >declaration of an argument or return type.''
  21. >
  22. >So, given that, is the following illegal?
  23. >
  24. >    new (int&)
  25. >
  26. >All the compilers I tried permitted it.
  27. >
  28.  
  29.     Wow, wonder what they allocated? IMHO: It does not make sense
  30. to allocate a reference, only an object.
  31. -- 
  32. ;----------------------------------------------------------------------
  33.         JOHN (MAX) SKALLER,         maxtal@extro.ucc.su.oz.au
  34.     Maxtal Pty Ltd, 6 MacKay St ASHFIELD, NSW 2131, AUSTRALIA
  35. ;--------------- SCIENTIFIC AND ENGINEERING SOFTWARE ------------------
  36.