Help on compiling K.Wilder's random number generator with Visio C++ .Net

L

ligong.yang

Hi all,

I got tortured by a very weird problem when I was using k. wilder's
random generator class in my program. PS: wilder's generator class can
be found at http://oldmill.uchicago.edu/~wilder/Code/random/.

Firstly, I got the notorious "fatal error C1010: unexpected end of file
while looking for precompiled header directive" error when I tried to
compile 'randtest.c' provided by wilder.

Then I use the solution of "creat new header file" in the project
properties to fix the problem. However, I got another series errors as
follows:
--------------------------------------------------------------------------------------------------------------------------------------------
randtest.cpp
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cerrno(18) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cerrno(18) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(17) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(17) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(17) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(17) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(17) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(17) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(18) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(18) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(18) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(18) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(18) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(18) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(19) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(19) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(19) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(19) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(19) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(19) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(20) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(20) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(20) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(20) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(20) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(20) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(21) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(21) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(21) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(21) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(21) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(21) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(22) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(22) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(22) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(22) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(22) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(22) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(23) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(23) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(23) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(23) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(23) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(23) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(24) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(24) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(24) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(24) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(24) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(24) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(25) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(25) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(25) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(25) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(26) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(26) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(26) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(26) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(27) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(27) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(27) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(27) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(27) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(27) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(28) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(28) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(28) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(28) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(28) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(28) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(29) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(29) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(29) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(29) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(29) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(29) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(30) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(30) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(30) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(30) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(30) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(30) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(31) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(31) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(31) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(31) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(31) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(31) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(32) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdio(32) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdlib(18) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdlib(18) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdlib(18) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdlib(18) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdlib(18) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdlib(18) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdlib(19) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdlib(19) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdlib(19) : error C2143: syntax error : missing '{'
before ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdlib(19) : error C2059: syntax error : ':'
d:\Program Files\Microsoft Visual Studio .NET
2003\Vc7\include\cstdlib(19) : error C2143: syntax error : missing '{'
before ':'
---------------------------------------------------------------------------------------------------------------------------------------------

It looks like I got something wrong in the standard lib-I dont know
what to do with this. Could anyone please help me out?

Cheers,

G
 
D

David Harmon

On 28 Dec 2006 10:52:35 -0800 in comp.lang.c++, (e-mail address removed)
wrote,
Then I use the solution of "creat new header file" in the project
properties to fix the problem. However, I got another series errors as
follows:

Please refer to the answer I gave you the previous time you posted
EXACTLY THE SAME question.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,968
Messages
2,570,152
Members
46,697
Latest member
AugustNabo

Latest Threads

Top