Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/SynTree/FunctionDecl.cc

    rde62360d r1db21619  
    1010// Created On       : Mon May 18 07:44:20 2015
    1111// Last Modified By : Peter A. Buhr
    12 // Last Modified On : Sat Jun 13 09:10:32 2015
    13 // Update Count     : 16
     12// Last Modified On : Mon Jul 13 18:11:44 2015
     13// Update Count     : 19
    1414//
    1515
     
    2222
    2323FunctionDecl::FunctionDecl( const std::string &name, DeclarationNode::StorageClass sc, LinkageSpec::Type linkage, FunctionType *type, CompoundStmt *statements, bool isInline, bool isNoreturn )
    24                 : Parent( name, sc, linkage ), type( type ), statements( statements ), isInline( isInline ), isNoreturn( isNoreturn ) {
     24                : Parent( name, sc, linkage ), type( type ), statements( statements ) {
     25        set_isInline( isInline );
     26        set_isNoreturn( isNoreturn );
    2527        // this is a brazen hack to force the function "main" to have C linkage
    2628        if ( name == "main" ) {
     
    3032
    3133FunctionDecl::FunctionDecl( const FunctionDecl &other )
    32         : Parent( other ), type( maybeClone( other.type ) ), statements( maybeClone( other.statements ) ), isInline( other.isInline ), isNoreturn( other.isNoreturn ) {
     34        : Parent( other ), type( maybeClone( other.type ) ), statements( maybeClone( other.statements ) ) {
    3335}
    3436
     
    5759                os << LinkageSpec::toString( get_linkage() ) << " ";
    5860        } // if
    59         if ( isInline ) {
     61        if ( get_isInline() ) {
    6062                os << "inline ";
    6163        } // if
    62         if ( isNoreturn ) {
     64        if ( get_isNoreturn() ) {
    6365                os << "_Noreturn ";
    6466        } // if
     
    9698                os << get_name() << ": ";
    9799        } // if
    98         if ( isInline ) {
     100        if ( get_isInline() ) {
    99101                os << "inline ";
    100102        } // if
    101         if ( isNoreturn ) {
     103        if ( get_isNoreturn() ) {
    102104                os << "_Noreturn ";
    103105        } // if
Note: See TracChangeset for help on using the changeset viewer.