help-gplusplus
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: g++ 3.3.2 '?:' operator compile error


From: Juergen Heinzl
Subject: Re: g++ 3.3.2 '?:' operator compile error
Date: Sat, 1 May 2004 18:35:26 +0000 (UTC)
User-agent: slrn/0.9.7.4 (Linux)

In article <KYDkc.10970$IO6.1182@twister.socal.rr.com>, Kyuso Cahi wrote:
> I have the following code that gives an error during compile:
[-]
The bug's in your code.

> // xxx.cc
> class A {
>  public:
>   static const int YES=1;
>   static const int NO=-1;
> };
[-]
int const A::YES;
int const A::NO;

> int main() {
>   double n=3.0;
>   if (A::YES > A::NO); // line 9
>   return (n>0.0) ? (A::YES) : (A::NO); // line 10
> }
[-]
Cheers,
Juergen

-- 
\ Real name     : Juergen Heinzl       \       no flames      /
 \ Email private : juergen@manannan.org \ send money instead /
  \ Photo gallery : www.manannan.org     \                  /


reply via email to

[Prev in Thread] Current Thread [Next in Thread]