home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #16 / NN_1992_16.iso / spool / comp / lang / cplus / 11545 < prev    next >
Encoding:
Text File  |  1992-07-25  |  2.1 KB  |  51 lines

  1. Newsgroups: comp.lang.c++
  2. Path: sparky!uunet!darwin.sura.net!mips!mips!munnari.oz.au!metro!extro.ucc.su.OZ.AU!maxtal
  3. From: maxtal@extro.ucc.su.OZ.AU (John MAX Skaller)
  4. Subject: Re: Language extensions for run-time type identification
  5. Message-ID: <1992Jul25.181214.26818@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: <rmartin.711829160@thor> <1992Jul23.175944.9090@microsoft.com> <1992Jul25.070247.3925@uunet.uu.net!mole-end>
  10. Date: Sat, 25 Jul 1992 18:12:14 GMT
  11. Lines: 38
  12.  
  13. In article <1992Jul25.070247.3925@uunet.uu.net!mole-end> mat@uunet.uu.net!mole-end writes:
  14. >
  15. >Eh?  Under the current proposal, if the class has no  ~const  members
  16. >AND IF IT HAS NO CONSTRUCTORS OR DESTRUCTORS it can be placed in ROM.
  17. >Complex  should probably have constructors or destructors, so it is left
  18. >out, but that has nothing to do with Humpty Alice Dumpty.
  19. >
  20. >On the other hand, under the current proposal, with no ~const members,
  21. >casting away const for classes can be reduced to the unsupported sort
  22. >of thing you are asking for.  The class declaration, by default, supports
  23. >bitwise const; with the appropriate declarations the meaning of const is
  24. >weakened for that class.  It's up to the implementor of the class.
  25.  
  26.     Can you have BOTH ~const member variables AND functions?
  27.  
  28. >
  29. >What more do you need?  
  30.  
  31.     It would be nice to be able to have constructors for
  32. romable objects. They would have to be restricted to the sorts
  33. of things that the COMPILER can EXECUTE at compile time.
  34.  
  35.     ROM double x=sin(1.3);
  36.     ROM complex y=sin(complex(2,3.4));
  37.  
  38. I guess this is too much to ask for, but you did ask 
  39. "What more do you need". I dont need the above but it would
  40. be desirable (saves me calculating the complex sine on
  41. a calculator, and constructing an image and then
  42. fiddling with the placement form of operator new)
  43.  
  44.  
  45.  
  46. -- 
  47. ;----------------------------------------------------------------------
  48.         JOHN (MAX) SKALLER,         maxtal@extro.ucc.su.oz.au
  49.     Maxtal Pty Ltd, 6 MacKay St ASHFIELD, NSW 2131, AUSTRALIA
  50. ;--------------- SCIENTIFIC AND ENGINEERING SOFTWARE ------------------
  51.