[cgma-dev] Re: compilling errors

Jason Kraftcheck kraftche at cae.wisc.edu
Mon Oct 20 13:36:24 CDT 2008


This is a GCC issue.  That is, GCC will allow a construct like:
  int myarray[i];
where 'i' need not be a constant (runtime array sizing.)  However, this is
part of neither the current C nor C++ standards (it will probably be in the
next C standard) and is therefore not portable.

We should update our configure script such that it adds the '-pedantic' flag
when the compiler is g++.  This will result in errors for many such
non-standard GCC features.

- jason


Tim Tautges wrote:
> I'm forwarding your message to cgma-dev; please forward correspondence
> to that list, which includes both me and the cgm-occ developers.
> 
> - tim
> 
> Leidy Suarez wrote:
>> Dear Tautges,
>> We have tried to compile the cubit_OCC library, but we have found some
>> errors. Maybe, they have been caused because we have not defined
>> something or we have not included some file. We will send you the
>> report of the compiling.
>> However, we have solved them, but we are not sure if they are correct.
>>
>> Briefly, the Compiler Error C2057 refers to:
>>
>> // C2057.cpp
>> int i;
>> // use the line below to resolve the error
>> // const int i = 8;
>>
>> int b[i];   // C2057
>>
>> In the other errors refer to that missing returns types.
>>
>> Thanks,
>> Leidy
>>
>>
>>
>>
>>
> 


-- 
"A foolish consistency is the hobgoblin of little minds" - Ralph Waldo Emerson




More information about the cgma-dev mailing list