public inbox for gcc-prs@sourceware.org
help / color / mirror / Atom feed
* c++/9935: g++-3.4 rejects legel code
@ 2003-03-04  9:26 thsv
  0 siblings, 0 replies; 2+ messages in thread
From: thsv @ 2003-03-04  9:26 UTC (permalink / raw)
  To: gcc-gnats


>Number:         9935
>Category:       c++
>Synopsis:       g++-3.4 rejects legel code
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    unassigned
>State:          open
>Class:          rejects-legal
>Submitter-Id:   net
>Arrival-Date:   Tue Mar 04 09:26:01 UTC 2003
>Closed-Date:
>Last-Modified:
>Originator:     thsv@bigfoot.com
>Release:        gcc version 3.4 20030302 (experimental) (and the for some time now)
>Organization:
>Environment:
g++-3.4 -v
Reading specs from /usr/local/lib/gcc-lib/i686-pc-linux-gnu/3.4/specs
Configured with: ../3.4/configure --enable-languages=c,c++,f77 --enable-shared --enable-threads=posix --program-suffix=-3.4 : (reconfigured) 
Thread model: posix
gcc version 3.4 20030302 (experimental)
>Description:
The attached code snippet gives the following error:

~> g++-3.4 -g -Wall -o slask slask.cpp
slask.cpp: In constructor `Array<X>::Array()':
slask.cpp:20: error: `Dims' has not been declared
slask.cpp: In constructor `Array<X>::Array(unsigned int)':
slask.cpp:21: error: `Dims' has not been declared
slask.cpp: In copy constructor `Array<X>::Array(const Array<X>&)':
slask.cpp:24: error: `Dims' has not been declared
slask.cpp:25: error: `Storage' has not been declared

While other compilers (3.2.2, 3.3 intel 7.0) accepts the code without warnings
>How-To-Repeat:
Just compile it
>Fix:

>Release-Note:
>Audit-Trail:
>Unformatted:
----gnatsweb-attachment----
Content-Type: application/octet-stream; name="slask.cpp"
Content-Transfer-Encoding: base64
Content-Disposition: attachment; filename="slask.cpp"

I2luY2x1ZGUgPHZhbGFycmF5PgoKdXNpbmcgbmFtZXNwYWNlIHN0ZDsKCnRlbXBsYXRlIDx0eXBl
bmFtZSBYLCBzaXplX3QgRElNUz4gY2xhc3MgX19hcnJheV9zdG9yYWdlCnsKcHJvdGVjdGVkOgoJ
dmFsYXJyYXk8c2l6ZV90PglEaW1zOwoJdmFsYXJyYXk8WD4JCVN0b3JhZ2U7CgoJX19hcnJheV9z
dG9yYWdlICgpIHtEaW1zLnJlc2l6ZSAoRElNUyk7fQoJX19hcnJheV9zdG9yYWdlIChzaXplX3Qg
c2l6ZSkge1N0b3JhZ2UucmVzaXplIChzaXplKTsgRGltcy5yZXNpemUgKERJTVMpO30KCgl2b2lk
IGNsZWFyICgpIHtTdG9yYWdlLnJlc2l6ZSgwKTt9Cn07Cgp0ZW1wbGF0ZSA8dHlwZW5hbWUgWD4g
Y2xhc3MgQXJyYXkgOiBwdWJsaWMgX19hcnJheV9zdG9yYWdlPFgsMT4KewpwdWJsaWM6CglBcnJh
eSAoKSB7RGltcyA9IDA7fQoJQXJyYXkgKHNpemVfdCBsZW5ndGgpOl9fYXJyYXlfc3RvcmFnZTxY
LDE+KGxlbmd0aCkge0RpbXNbMF0gPSBsZW5ndGg7fQoJQXJyYXkgKGNvbnN0IEFycmF5PFg+ICZy
aWdodCk6X19hcnJheV9zdG9yYWdlPFgsMT4ocmlnaHQuVG90YWxfU2l6ZSkKCXsKCQlEaW1zID0g
cmlnaHQuRGltczsKCQlTdG9yYWdlID0gcmlnaHQuU3RvcmFnZTsKCX0KCgl+QXJyYXkoKSB7X19h
cnJheV9zdG9yYWdlPFgsMT46OmNsZWFyICgpO30KfTsKCmludCBtYWluICgpCnsKCUFycmF5PGRv
dWJsZT4gQTsKCglyZXR1cm4gMDsKfQo=


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: c++/9935: g++-3.4 rejects legel code
@ 2003-03-04 15:34 bangerth
  0 siblings, 0 replies; 2+ messages in thread
From: bangerth @ 2003-03-04 15:34 UTC (permalink / raw)
  To: gcc-bugs, gcc-prs, nobody, thsv

Synopsis: g++-3.4 rejects legel code

State-Changed-From-To: open->closed
State-Changed-By: bangerth
State-Changed-When: Tue Mar  4 15:34:50 2003
State-Changed-Why:
    Not a bug. If accessing members of the base class, you 
    need to write this->Dims, etc.
    
    There's a section in the non-bugs chapter of the manual
    on this.
    
    W.

http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gcc&pr=9935


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2003-03-04 15:34 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-03-04  9:26 c++/9935: g++-3.4 rejects legel code thsv
2003-03-04 15:34 bangerth

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).