long follow by long is illegal

S

Skybuck Flying

unsigned long long int __a; /* Factor in congruential formula. */

C:\C TESTEN\TestNRand48\Main.cpp(29) : error C2632: 'long' followed by
'long' is illegal

???
 
J

Jens.Toerring

Skybuck Flying said:
unsigned long long int __a; /* Factor in congruential formula. */
C:\C TESTEN\TestNRand48\Main.cpp(29) : error C2632: 'long' followed by
'long' is illegal

Obviously, your compiler doesn't know anything about the "long long"
type, introduced by the C99 standard (but already supported by some
compilers before that time). Get a different compiler or rewrite your
code to work without "long long" types.

Regards, Jens
 
R

Richard Bos

Skybuck Flying said:
unsigned long long int __a; /* Factor in congruential formula. */

C:\C TESTEN\TestNRand48\Main.cpp(29) : error C2632: 'long' followed by
^^^
Ahem.
'long' is illegal

C++ is off-topic here.

Even so, you could encounter this error using a C compiler; (unsigned)
long long is a C99 type, and doesn't exist in the C89 Standard. From a
compiler that doesn't support C99 yet, I would expect an error like the
above, certainly when invoked in strict ISO mode.

Richard
 
E

Emmanuel Delahaye

Skybuck Flying said:
unsigned long long int __a; /* Factor in congruential formula. */

C:\C TESTEN\TestNRand48\Main.cpp(29) : error C2632: 'long' followed by
'long' is illegal

It's illegal in C90. It's legel in C99. Get a newer compiler.
 
D

Dan Pop

In said:
The stuff should be compiled using gcc or so, not visual cpp, :(

And, if you invoke gcc in conforming mode, it will tell you that:

warning: ISO C90 does not support `long long'

Dan
 
P

Peter Shaggy Haywood

Groovy hepcat Skybuck Flying was jivin' on Wed, 7 Jul 2004 15:04:14
+0200 in comp.lang.c.
long follow by long is illegal's a cool scene! Dig it!
unsigned long long int __a; /* Factor in congruential formula. */

In addition to what others have told you, there's another problem
here. Identifiers beginning with two underscores are reserved for the
implementation in all circumstances. You are invading implementation
name space and risking undefined behaviour.

--

Dig the even newer still, yet more improved, sig!

http://alphalink.com.au/~phaywood/
"Ain't I'm a dog?" - Ronny Self, Ain't I'm a Dog, written by G. Sherry & W. Walker.
I know it's not "technically correct" English; but since when was rock & roll "technically correct"?
 

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

No members online now.

Forum statistics

Threads
474,145
Messages
2,570,824
Members
47,370
Latest member
desertedtyro29

Latest Threads

Top