Re: [Flightgear-devel] [Simgear-cvslogs] CVS: source/simgear/math SGGeodesy.cxx, 1.8, 1.9

2008-12-27 Thread Tim Moore
James Turner wrote:
 On 27 Dec 2008, at 08:16, Tim Moore wrote:
 
 Modified Files:
  SGGeodesy.cxx
 Log Message:
 Fix include path
 
 snip
 
 *** SGGeodesy.cxx26 Dec 2008 12:08:28 -  1.8
 --- SGGeodesy.cxx27 Dec 2008 08:16:03 -  1.9
 ***
 *** 22,26 
  #include cmath

 ! #include structure/exception.hxx
  #include SGMath.hxx

 --- 22,26 
  #include cmath

 ! #include simgear/structure/exception.hxx
  #include SGMath.hxx
 
 This is interesting - since we're in an implementation file, not a  
 public header, I regard my version as a 'better' choice than using a  
 system include, with the simgear prefix. Are you changing this for the  
 sake of style, consistency or correctness? (Or maybe all three :)
Correctness, in the sense that I can't compile SimGear without this change. 
Also 
consistency, since in SimGear we consistently refer to headers from other 
SimGear modules using #include simgear/ The important part of the change 
is adding simgear to the include path.

 doesn't necessarily mean public header, just (at least, in gcc) look in 
standard places, including those added by -I.

Tim

--
___
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel


Re: [Flightgear-devel] [Simgear-cvslogs] CVS: source/simgear/math SGGeodesy.cxx, 1.8, 1.9

2008-12-27 Thread James Turner

On 27 Dec 2008, at 10:19, Tim Moore wrote:

 Correctness, in the sense that I can't compile SimGear without this  
 change. Also
 consistency, since in SimGear we consistently refer to headers from  
 other
 SimGear modules using #include simgear/ The important part of  
 the change
 is adding simgear to the include path.

  doesn't necessarily mean public header, just (at least, in  
 gcc) look in
 standard places, including those added by -I.

Interesting - I'm testing all these changes on a VMware-Ubunutu image,  
and this compiled fine. I do have simgear 'installed' to /usr/local  
though, maybe that means it's picking up the installed headers anyway.

The different semantic meanings of  vs  is something I've  
struggled with in the past, and there are some Mac-specific  
conventions which are probably rather too strongly embedded in my  
brain, so I shall simply cease to worry about this, and stick to the  
house style. As you noted, GCC doesn't make much distinction at all.

James


--
___
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel


Re: [Flightgear-devel] [Simgear-cvslogs] CVS: source/simgear/math SGGeodesy.cxx, 1.8, 1.9

2008-12-27 Thread Vivian Meazza
Tim Moore wrote

 
 James Turner wrote:
  On 27 Dec 2008, at 08:16, Tim Moore wrote:
 
  Modified Files:
 SGGeodesy.cxx
  Log Message:
  Fix include path
 
  snip
 
  *** SGGeodesy.cxx  26 Dec 2008 12:08:28 -  1.8
  --- SGGeodesy.cxx  27 Dec 2008 08:16:03 -  1.9
  ***
  *** 22,26 
   #include cmath
 
  ! #include structure/exception.hxx
   #include SGMath.hxx
 
  --- 22,26 
   #include cmath
 
  ! #include simgear/structure/exception.hxx
   #include SGMath.hxx
 
  This is interesting - since we're in an implementation file, not a
  public header, I regard my version as a 'better' choice than using a
  system include, with the simgear prefix. Are you changing this for the
  sake of style, consistency or correctness? (Or maybe all three :)
 Correctness, in the sense that I can't compile SimGear without this
 change. Also
 consistency, since in SimGear we consistently refer to headers from other
 SimGear modules using #include simgear/ The important part of the
 change
 is adding simgear to the include path.
 
  doesn't necessarily mean public header, just (at least, in gcc)
 look in
 standard places, including those added by -I.
 

Hmmm, neither version compiles here with MSVC9. Gives the following error:

source\simgear\math\SGMisc.hxx(27) : error C2059: syntax error :
'L_TYPE_raw'

followed by hundreds of errors like this:

1d:\cygwin\simgear-cvs\source\simgear\math\SGMisc.hxx(28) : error C2143:
syntax error : missing ')' before '}'
1d:\cygwin\simgear-cvs\source\simgear\math\SGMisc.hxx(28) : error C2143:
syntax error : missing '}' before ')'

Perhaps Fred has the answer

Vivian



--
___
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel


Re: [Flightgear-devel] [Simgear-cvslogs] CVS: source/simgear/math SGGeodesy.cxx, 1.8, 1.9

2008-12-27 Thread Yon Uriarte
Hi,
add#undef max
#undef min
at the top of that SGMisc.hxx, just before class ...

I thought it was a local problem at my end cause I'm always changing things,
heh.
It's been that way for a few days.

hth,
 yon



On Sat, Dec 27, 2008 at 12:21 PM, Vivian Meazza
vivian.mea...@lineone.netwrote:


 Hmmm, neither version compiles here with MSVC9. Gives the following error:

 source\simgear\math\SGMisc.hxx(27) : error C2059: syntax error :
 'L_TYPE_raw'

 followed by hundreds of errors like this:

 1d:\cygwin\simgear-cvs\source\simgear\math\SGMisc.hxx(28) : error C2143:
 syntax error : missing ')' before '}'
 1d:\cygwin\simgear-cvs\source\simgear\math\SGMisc.hxx(28) : error C2143:
 syntax error : missing '}' before ')'

 Perhaps Fred has the answer

 Vivian


--
___
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel


Re: [Flightgear-devel] [Simgear-cvslogs] CVS: source/simgear/math SGGeodesy.cxx, 1.8, 1.9

2008-12-27 Thread James Turner

On 27 Dec 2008, at 11:21, Vivian Meazza wrote:

 Hmmm, neither version compiles here with MSVC9. Gives the following  
 error:

 source\simgear\math\SGMisc.hxx(27) : error C2059: syntax error :
 'L_TYPE_raw'

 followed by hundreds of errors like this:

 1d:\cygwin\simgear-cvs\source\simgear\math\SGMisc.hxx(28) : error  
 C2143:
 syntax error : missing ')' before '}'
 1d:\cygwin\simgear-cvs\source\simgear\math\SGMisc.hxx(28) : error  
 C2143:
 syntax error : missing '}' before ')'

 Perhaps Fred has the answer

Yuck, sorry about this Vivian - I'm not sure what's going on there.

Maybe I introduced some odd whitespace or line-endings to the header  
or source file? As far as I know, all my editors are set to soft-tabs  
and LF line-endings, and that's what all the existing sources use.

Again, apologies.

James

--
___
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel


Re: [Flightgear-devel] [Simgear-cvslogs] CVS: source/simgear/math SGGeodesy.cxx, 1.8, 1.9

2008-12-27 Thread Vivian Meazza
James Turner wrote

 
 On 27 Dec 2008, at 11:21, Vivian Meazza wrote:
 
  Hmmm, neither version compiles here with MSVC9. Gives the following
  error:
 
  source\simgear\math\SGMisc.hxx(27) : error C2059: syntax error :
  'L_TYPE_raw'
 
  followed by hundreds of errors like this:
 
  1d:\cygwin\simgear-cvs\source\simgear\math\SGMisc.hxx(28) : error
  C2143:
  syntax error : missing ')' before '}'
  1d:\cygwin\simgear-cvs\source\simgear\math\SGMisc.hxx(28) : error
  C2143:
  syntax error : missing '}' before ')'
 
  Perhaps Fred has the answer
 
 Yuck, sorry about this Vivian - I'm not sure what's going on there.
 
 Maybe I introduced some odd whitespace or line-endings to the header
 or source file? As far as I know, all my editors are set to soft-tabs
 and LF line-endings, and that's what all the existing sources use.
 
 Again, apologies.
 

It's just MSVC9 being picky, not your fault, no apology needed.

Vivian



--
___
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel