Apologies for forgetting to put in a subject line in my last email.

I am using :
    gcc version 4.1.3 20070929 (prerelease) (ubuntu 4.1.2-16ubuntu2)
    gccxml   built from source tree checked out 28/12/2007

My header file to be parsed is 
__________________________________________________________________________

#ifndef TESTVECTOR
#define TESTVECTOR

class egclass{};

template <class T>  
class vector {
  vector(unsigned long i, const egclass  = egclass()  ){}
};

class xvector {
  xvector(unsigned long i, const egclass  = egclass()  ){}
};

template class vector<double>;

#endif
____________________________________________________________________________

Two lines of interest in the resulting xml file  are as follows:

_____________________________________________________________________________________________________
<Constructor id="_138" name="vector" context="_40" access="private" 
mangled="_ZN6vectorIdEC1Em7egclass *INTERNAL* " 
demangled="vector&lt;double&gt;::vector(unsigned long, egclass)" 
location="f1:9" file="f1" line="9" inline="1">
    <Argument name="i" type="_149" location="f1:9" file="f1" line="9"/>
    <Argument type="_90c" location="f1:9" file="f1" line="9" 
default="&lt;gccxml-cast-expr&gt;"/>
  
    </Constructor>
  
    <Constructor id="_145" name="xvector" context="_89" access="private" 
mangled="_ZN7xvectorC1Em7egclass *INTERNAL* " 
demangled="xvector::xvector(unsigned long, egclass)" location="f1:13" file="f1" 
line="13" inline="1">
    <Argument name="i" type="_149" location="f1:13" file="f1" line="13"/>
    <Argument type="_90c" location="f1:13" file="f1" line="13" 
default="egclass()"/>
  </Constructor> 
______________________________________________________________________________________________________

The default values look interesting. gccxml does pick up that there is a 
default value
for the second parameter of the constructor in both the templated and 
non-templated classes.
However  &lt;gccxml-cast-expr&gt; is something I do not understand, should it 
not be the same as egclass() ?
I am actualy using pygccxml and that does not pick up the fact there is actual 
a default value.




      __________________________________________________________
Sent from Yahoo! Mail - a smarter inbox http://uk.mail.yahoo.com

_______________________________________________
gccxml mailing list
[email protected]
http://www.gccxml.org/mailman/listinfo/gccxml

Reply via email to