home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!cis.ohio-state.edu!zaphod.mps.ohio-state.edu!sol.ctr.columbia.edu!destroyer!ubc-cs!mala.bc.ca!epp
- From: epp@mala.bc.ca (Lorne Epp)
- Newsgroups: comp.lang.c++
- Subject: Re: Borland C++ 3.1 fails to conform to C++ Standard
- Message-ID: <1992Jul24.133738.597@mala.bc.ca>
- Date: 24 Jul 92 13:37:38 -0700
- References: <j_ohearn.711991770@dn73>
- Distribution: world
- Organization: Malaspina College
- Lines: 27
-
- In article <j_ohearn.711991770@dn73>, j_ohearn@dsg4.dse.beckman.com () writes:
- >
- > class Vector
- > {
- > double huge *data;
- > unsigned long low, high;
- >
- > public:
- >
- > Vector ( unsigned long, unsigned long );
- > ~Vector(){ delete[] data; }
- >
- > double& operator()( unsigned long i )
- > {
- > return data[i - low]; //Line that offends ver 3.1 but compiled without
- > //error under 3.0
- > }
- > };
- >
- > The above class compiled and functioned successfully under version 3.0
- > but under version 3.1 I receive the error message:
- > "Reference initialized with 'double' requires lvalue of type 'double'"
- > which referred to the line I have indicated in the above class listing.
- >
-
- Just a note: I have received the same error message for similar code in
- Turbo C++ 3.0.
-