Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/SynTree/FunctionDecl.cc

    r50377a4 rec010a9  
    6363}
    6464
    65 void FunctionDecl::print( std::ostream &os, Indenter indent ) const {
     65void FunctionDecl::print( std::ostream &os, int indent ) const {
    6666        using std::endl;
    6767        using std::string;
    6868
    69         if ( name != "" ) {
    70                 os << name << ": ";
     69        if ( get_name() != "" ) {
     70                os << get_name() << ": ";
    7171        } // if
    72         if ( linkage != LinkageSpec::Cforall ) {
    73                 os << LinkageSpec::linkageName( linkage ) << " ";
     72        if ( get_linkage() != LinkageSpec::Cforall ) {
     73                os << LinkageSpec::linkageName( get_linkage() ) << " ";
    7474        } // if
    7575
    76         printAll( attributes, os, indent );
     76        printAll( get_attributes(), os, indent );
    7777
    7878        get_storageClasses().print( os );
    7979        get_funcSpec().print( os );
    8080
    81         if ( type ) {
    82                 type->print( os, indent );
     81        if ( get_type() ) {
     82                get_type()->print( os, indent );
    8383        } else {
    8484                os << "untyped entity ";
     
    8686
    8787        if ( statements ) {
    88                 os << indent << "... with body " << endl << indent+1;
    89                 statements->print( os, indent+1 );
     88                os << string( indent + 2, ' ' ) << "with body " << endl;
     89                os << string( indent + 4, ' ' );
     90                statements->print( os, indent + 4 );
    9091        } // if
    9192}
    9293
    93 void FunctionDecl::printShort( std::ostream &os, Indenter indent ) const {
     94void FunctionDecl::printShort( std::ostream &os, int indent ) const {
    9495        using std::endl;
    9596        using std::string;
    9697
    97         if ( name != "" ) {
    98                 os << name << ": ";
     98        if ( get_name() != "" ) {
     99                os << get_name() << ": ";
    99100        } // if
     101
     102        // xxx - should printShort print attributes?
    100103
    101104        get_storageClasses().print( os );
    102105        get_funcSpec().print( os );
    103106
    104         if ( type ) {
    105                 type->print( os, indent );
     107        if ( get_type() ) {
     108                get_type()->print( os, indent );
    106109        } else {
    107110                os << "untyped entity ";
Note: See TracChangeset for help on using the changeset viewer.