home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!cs.utexas.edu!sun-barr!sh.wide!wnoc-tyo-news!ricohgwy!pattyjr!lsijgw!pnori
- From: pnori@lsi-j.co.jp (Pochi NORIMATSU)
- Newsgroups: comp.std.c++
- Subject: Ambiguity in member pointer declaration
- Message-ID: <PNORI.92Dec14161301@hyperion.lsi-j.co.jp>
- Date: 14 Dec 92 07:13:01 GMT
- Sender: news@lsi-j.co.jp
- Organization: LSI Japan Co. Ltd., Tokyo, Japan
- Lines: 25
- Nntp-Posting-Host: hyperion
-
- Sorry if this is on a FAQ list.
-
- Assuming X, Y and Z are class names, how should
-
- X::Y::Z::*foo;
-
- be interpreted?
-
- 1. foo is a pointer to member of class ::Y::Z of type X.
- ('X' is a decl-specifier and '::Y::Z::*foo' is a declarator)
-
- 2. foo is a pointer to member of class ::Z of type X::Y.
- ('X::Y' is a decl-specifier and '::Z::*foo' is a declarator)
-
- 3. X::Y::Z is a decl-specifier and ::*mptr is an error.
-
- IMHO, correct interpretation should be 3, but I'm not sure.
-
- Please E-mail me and I'll post a summary.
-
- Thanks in advance!
- --
- Yasutoshi (Pochi) Norimatsu | Never worry about theory as long as
- pnori@lsi-j.co.jp | the machinery does what it's supposed
- LSI Japan Co. Ltd., Tokyo, JAPAN | to do. -- R. A. Heinlein
-