delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2000/02/11/05:10:05

Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT sourceware DOT cygnus DOT com>
List-Archive: <http://sourceware.cygnus.com/ml/cygwin/>
List-Post: <mailto:cygwin AT sourceware DOT cygnus DOT com>
List-Help: <mailto:cygwin-help AT sourceware DOT cygnus DOT com>, <http://sourceware.cygnus.com/ml/#faqs>
Sender: cygwin-owner AT sourceware DOT cygnus DOT com
Delivered-To: mailing list cygwin AT sourceware DOT cygnus DOT com
Message-ID: <000c01bf7478$b5aee9e0$484266ca@dc>
From: wang-zy AT jlonline DOT com
To: <cygwin AT sourceware DOT cygnus DOT com>
Subject: auto_ptr's problem
Date: Fri, 11 Feb 2000 18:13:20 +0800
MIME-Version: 1.0
X-Priority: 3
X-MSMail-Priority: Normal
X-Mailer: Microsoft Outlook Express 5.00.2314.1300
X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2314.1300

------=_NextPart_000_0008_01BF74BB.AD85D9C0
Content-Type: multipart/alternative;
	boundary="----=_NextPart_001_0009_01BF74BB.AD85D9C0"


------=_NextPart_001_0009_01BF74BB.AD85D9C0
Content-Type: text/plain;
	charset="gb2312"
Content-Transfer-Encoding: quoted-printable

Hello, everyone.
=20
I use Cygwin B20.1 under Win98.
I'm in trouble now with the simple application (which I believe to be =
correct).
Here is the code:
=20
#include <memory>
using namespace std;
class A
{
public:
    A() : b(new int(8))
    {
    }
    auto_ptr<int> const b; // I also tried to delete the const
};

=20
When I compile it, the compiler output:
=20
t.cpp:11: syntax error before `const'
t.cpp: In method `A::A()':
t.cpp:8: class `A' does not have any field named `b'

I'm wondering is this a bug.

------=_NextPart_001_0009_01BF74BB.AD85D9C0
Content-Type: text/html;
	charset="gb2312"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META content=3D"text/html; charset=3Dgb2312" http-equiv=3DContent-Type>
<META content=3D"MSHTML 5.00.2314.1000" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=3D#ffffff>
<DIV><FONT face=3DArial size=3D2>Hello, everyone.</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>I use Cygwin B20.1 under =
Win98.</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>I'm in&nbsp;trouble now with&nbsp;the =
simple=20
application (which I believe to be correct).</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>Here is the code:</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>&nbsp;</DIV></FONT>
<DIV><FONT face=3DArial size=3D2>#include &lt;memory&gt;</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>using namespace std;</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>class =
A<BR>{<BR>public:<BR>&nbsp;&nbsp;&nbsp; A() :=20
b(new int(8))<BR>&nbsp;&nbsp;&nbsp; {<BR>&nbsp;&nbsp;&nbsp;=20
}<BR>&nbsp;&nbsp;&nbsp; auto_ptr&lt;int&gt; const b; // I also tried to =
delete=20
the const<BR>};<BR></FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>When I compile it, the compiler=20
output:</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>t.cpp:11: syntax error before =
`const'<BR>t.cpp: In=20
method `A::A()':<BR>t.cpp:8: class `A' does not have any field named=20
`b'</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>
<DIV>&nbsp;</DIV></DIV></FONT>
<DIV><FONT face=3DArial size=3D2>I'm wondering is this a =
bug.</FONT><FONT face=3DArial=20
size=3D2></DIV></FONT></BODY></HTML>

------=_NextPart_001_0009_01BF74BB.AD85D9C0--

------=_NextPart_000_0008_01BF74BB.AD85D9C0
Content-Type: application/octet-stream;
	name="cygcheck.out"
Content-Transfer-Encoding: quoted-printable
Content-Disposition: attachment;
	filename="cygcheck.out"


Cygnus Win95/NT Configuration Diagnostics
Current System Time: Fri Feb 11 17:36:04 2000

Win9X Ver 4.10 build 67766222 =20

Path:	/CYGNUS/CYGWIN~1/H-I586~1/BIN
	/WINDOWS
	/WINDOWS/COMMAND
	/PROGRA~1/BORLAND/CBUILD~1/BIN
	/PROGRA~1/BORLAND/CBUILD~1/PROJECTS/BPL

SysDir: C:\WINDOWS\SYSTEM
WinDir: C:\WINDOWS

MAKE_MODE =3D `UNIX'
PWD =3D `/cygnus/cygwin-b20'

!C: =3D `C:\CYGNUS\CYGWIN~1'
CMDLINE =3D `bash'
COMSPEC =3D `C:\WINDOWS\COMMAND.COM'
HOSTNAME =3D `njptt'
HOSTTYPE =3D `i586'
MACHTYPE =3D `i586-pc-cygwin32'
OSTYPE =3D `cygwin32'
PROMPT =3D `$p$g'
SHELL =3D `/bin/sh'
SHLVL =3D `1'
TEMP =3D `C:\WINDOWS\TEMP'
TERM =3D `cygwin'
TMP =3D `C:\WINDOWS\TEMP'
WINBOOTDIR =3D `C:\WINDOWS'
WINDIR =3D `C:\WINDOWS'
_ =3D `/CYGNUS/CYGWIN~1/H-I586~1/BIN/cygcheck'

HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Menu=
Order\Start Menu\&Programs\Cygnus Solutions
  (default) =3D (unsupported type)
HKEY_CURRENT_USER\Software\Cygnus Solutions
HKEY_CURRENT_USER\Software\Cygnus Solutions\CYGWIN.DLL setup
HKEY_CURRENT_USER\Software\Cygnus Solutions\CYGWIN.DLL setup\b15.0
HKEY_CURRENT_USER\Software\Cygnus Solutions\CYGWIN.DLL =
setup\b15.0\mounts
HKEY_CURRENT_USER\Software\Cygnus Solutions\CYGWIN.DLL =
setup\b15.0\mounts\00
  (default) =3D `C:'
  unix =3D `/'
  fbinary =3D 0x00000000
  fsilent =3D 0x00000000
HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Uninstall\Cy=
gnus Cygwin B20
  (default) =3D `C:\WINDOWS\IsUninst.exe =
-fc:\cygnus\cygwin-b20\Uninst.isu'
  DisplayName =3D `Cygwin B20'
HKEY_LOCAL_MACHINE\Software\Cygnus Solutions
HKEY_LOCAL_MACHINE\Software\Cygnus Solutions\GNUPro
HKEY_LOCAL_MACHINE\Software\Cygnus Solutions\GNUPro\i586-cygwin32
HKEY_LOCAL_MACHINE\Software\Cygnus =
Solutions\GNUPro\i586-cygwin32\i586-cygwin32
HKEY_LOCAL_MACHINE\Software\Cygnus =
Solutions\GNUPro\i586-cygwin32\i586-cygwin32\cygwin-B20.1
  (default) =3D `c:\cygnus\cygwin-b20'
HKEY_LOCAL_MACHINE\Software\Cygnus Solutions\CYGWIN.DLL setup
HKEY_LOCAL_MACHINE\Software\Cygnus Solutions\CYGWIN.DLL setup\b15.0
HKEY_LOCAL_MACHINE\Software\Cygnus Solutions\CYGWIN.DLL =
setup\b15.0\mounts
HKEY_LOCAL_MACHINE\Software\Cygnus Solutions\CYGWIN.DLL =
setup\b15.0\mounts\00
HKEY_LOCAL_MACHINE\Software\Cygnus Solutions\CYGWIN.DLL =
setup\b15.0\mounts\01
HKEY_LOCAL_MACHINE\Software\Cygnus Solutions\CYGWIN.DLL =
setup\b15.0\mounts\02
HKEY_LOCAL_MACHINE\Software\Cygnus Solutions\CYGWIN.DLL =
setup\b15.0\mounts\03
HKEY_LOCAL_MACHINE\Software\Cygnus Solutions\CYGWIN.DLL =
setup\b15.0\mounts\04
HKEY_LOCAL_MACHINE\Software\Cygnus Solutions\CYGWIN.DLL =
setup\b15.0\mounts\05
HKEY_LOCAL_MACHINE\Software\Cygnus Solutions\CYGWIN.DLL =
setup\b15.0\mounts\06
HKEY_LOCAL_MACHINE\Software\Cygnus Solutions\CYGWIN.DLL =
setup\b15.0\mounts\07
HKEY_LOCAL_MACHINE\Software\Cygnus Solutions\CYGWIN.DLL =
setup\b15.0\mounts\08
HKEY_LOCAL_MACHINE\Software\Cygnus Solutions\CYGWIN.DLL =
setup\b15.0\mounts\09
HKEY_LOCAL_MACHINE\Software\Cygnus Solutions\CYGWIN.DLL =
setup\b15.0\mounts\0A
HKEY_LOCAL_MACHINE\Software\Cygnus Solutions\CYGWIN.DLL =
setup\b15.0\mounts\0B
HKEY_LOCAL_MACHINE\Software\Cygnus Solutions\CYGWIN.DLL =
setup\b15.0\mounts\0C
HKEY_LOCAL_MACHINE\Software\Cygnus Solutions\CYGWIN.DLL =
setup\b15.0\mounts\0D
HKEY_LOCAL_MACHINE\Software\Cygnus Solutions\CYGWIN.DLL =
setup\b15.0\mounts\0E
HKEY_LOCAL_MACHINE\Software\Cygnus Solutions\CYGWIN.DLL =
setup\b15.0\mounts\0F
HKEY_LOCAL_MACHINE\Software\Cygnus Solutions\CYGWIN.DLL =
setup\b15.0\mounts\10
HKEY_LOCAL_MACHINE\Software\Cygnus Solutions\CYGWIN.DLL =
setup\b15.0\mounts\11
HKEY_LOCAL_MACHINE\Software\Cygnus Solutions\CYGWIN.DLL =
setup\b15.0\mounts\12
HKEY_LOCAL_MACHINE\Software\Cygnus Solutions\CYGWIN.DLL =
setup\b15.0\mounts\13
HKEY_LOCAL_MACHINE\Software\Cygnus Solutions\CYGWIN.DLL =
setup\b15.0\mounts\14
HKEY_LOCAL_MACHINE\Software\Cygnus Solutions\CYGWIN.DLL =
setup\b15.0\mounts\15
HKEY_LOCAL_MACHINE\Software\Cygnus Solutions\CYGWIN.DLL =
setup\b15.0\mounts\16
HKEY_LOCAL_MACHINE\Software\Cygnus Solutions\CYGWIN.DLL =
setup\b15.0\mounts\17
HKEY_LOCAL_MACHINE\Software\Cygnus Solutions\CYGWIN.DLL =
setup\b15.0\mounts\18
HKEY_LOCAL_MACHINE\Software\Cygnus Solutions\CYGWIN.DLL =
setup\b15.0\mounts\19
HKEY_LOCAL_MACHINE\Software\Cygnus Solutions\CYGWIN.DLL =
setup\b15.0\mounts\1A
HKEY_LOCAL_MACHINE\Software\Cygnus Solutions\CYGWIN.DLL =
setup\b15.0\mounts\1B
HKEY_LOCAL_MACHINE\Software\Cygnus Solutions\CYGWIN.DLL =
setup\b15.0\mounts\1C
HKEY_LOCAL_MACHINE\Software\Cygnus Solutions\CYGWIN.DLL =
setup\b15.0\mounts\1D
HKEY_LOCAL_MACHINE\Software\Cygnus Solutions\Cygwin B20
HKEY_LOCAL_MACHINE\Software\Cygnus Solutions\Cygwin B20\B20.1

a:\ fd           N/A    N/A                   =20
c:\ hd  FAT32   3084Mb  71% CP    UN          =20
d:\ cd           N/A    N/A                   =20

C:    /        native  text!=3Dbinary

Found: C:\CYGNUS\CYGWIN~1\H-I586~1\BIN\bash.exe
Found: C:\CYGNUS\CYGWIN~1\H-I586~1\BIN\cat.exe
Not Found: cpp (good!)
Found: C:\CYGNUS\CYGWIN~1\H-I586~1\BIN\find.exe
Found: C:\WINDOWS\COMMAND\find.exe
Warning: C:\CYGNUS\CYGWIN~1\H-I586~1\BIN\find.exe hides =
C:\WINDOWS\COMMAND\find.exe
Found: C:\CYGNUS\CYGWIN~1\H-I586~1\BIN\gcc.exe
Found: C:\CYGNUS\CYGWIN~1\H-I586~1\BIN\gdb.exe
Found: C:\CYGNUS\CYGWIN~1\H-I586~1\BIN\ld.exe
Found: C:\CYGNUS\CYGWIN~1\H-I586~1\BIN\ls.exe
Found: C:\CYGNUS\CYGWIN~1\H-I586~1\BIN\make.exe
Found: C:\PROGRA~1\BORLAND\CBUILD~1\BIN\make.exe
Warning: C:\CYGNUS\CYGWIN~1\H-I586~1\BIN\make.exe hides =
C:\PROGRA~1\BORLAND\CBUILD~1\BIN\make.exe
Found: C:\CYGNUS\CYGWIN~1\H-I586~1\BIN\sh.exe

  371k 1998/12/01 C:\CYGNUS\CYGWIN~1\H-I586~1\BIN\cygtcl80.dll - =
os=3D4.0 img=3D1.0 sys=3D4.0
                  "cygtcl80.dll" v0.0 ts=3D1998/12/1 16:25
    5k 1998/12/01 C:\CYGNUS\CYGWIN~1\H-I586~1\BIN\cygtclpip80.dll - =
os=3D4.0 img=3D1.0 sys=3D4.0
   10k 1998/12/01 C:\CYGNUS\CYGWIN~1\H-I586~1\BIN\cygtclreg80.dll - =
os=3D4.0 img=3D1.0 sys=3D4.0
                  "cygtclreg80.dll" v0.0 ts=3D1998/12/1 16:25
  600k 1998/12/01 C:\CYGNUS\CYGWIN~1\H-I586~1\BIN\cygtk80.dll - os=3D4.0 =
img=3D1.0 sys=3D4.0
                  "cygtk80.dll" v0.0 ts=3D1998/12/1 16:28
  446k 1998/12/03 C:\CYGNUS\CYGWIN~1\H-I586~1\BIN\cygwin1.dll - os=3D4.0 =
img=3D1.0 sys=3D4.0
                  "cygwin1.dll" v0.0 ts=3D1998/12/4 12:39
Use -h to see help about each section


------=_NextPart_000_0008_01BF74BB.AD85D9C0
Content-Type: text/plain; charset=us-ascii

--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe AT sourceware DOT cygnus DOT com
------=_NextPart_000_0008_01BF74BB.AD85D9C0--

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019