Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/CodeGen/FixNames.cc

    ra7c90d4 raaa1a99a  
    99// Author           : Richard C. Bilson
    1010// Created On       : Mon May 18 07:44:20 2015
    11 // Last Modified By : Peter A. Buhr
    12 // Last Modified On : Mon Mar  6 23:32:08 2017
    13 // Update Count     : 15
     11// Last Modified By : Rob Schluntz
     12// Last Modified On : Mon Apr 11 15:38:10 2016
     13// Update Count     : 1
    1414//
    1515
     
    3939        std::string mangle_main() {
    4040                FunctionType* main_type;
    41                 std::unique_ptr<FunctionDecl> mainDecl { new FunctionDecl( "main", DeclarationNode::StorageClasses(), LinkageSpec::Cforall,
    42                                                                                                                                    main_type = new FunctionType( Type::Qualifiers(), true ), nullptr )
    43                                 };
     41                std::unique_ptr<FunctionDecl> mainDecl { new FunctionDecl(
     42                        "main",
     43                        DeclarationNode::NoStorageClass,
     44                        LinkageSpec::Cforall,
     45                        main_type = new FunctionType( Type::Qualifiers(), true ),
     46                        nullptr, false, false
     47                ) };
    4448                main_type->get_returnVals().push_back(
    45                         new ObjectDecl( "", DeclarationNode::StorageClasses(), LinkageSpec::Cforall, 0, new BasicType( Type::Qualifiers(), BasicType::SignedInt ), nullptr )
     49                        new ObjectDecl( "", DeclarationNode::NoStorageClass, LinkageSpec::Cforall, 0, new BasicType( Type::Qualifiers(), BasicType::SignedInt ), nullptr )
    4650                );
    4751
    48                 auto && name = SymTab::Mangler::mangle( mainDecl.get() );
     52                auto&& name = SymTab::Mangler::mangle( mainDecl.get() );
    4953                // std::cerr << name << std::endl;
    5054                return name;
     
    5256        std::string mangle_main_args() {
    5357                FunctionType* main_type;
    54                 std::unique_ptr<FunctionDecl> mainDecl { new FunctionDecl( "main", DeclarationNode::StorageClasses(), LinkageSpec::Cforall,
    55                                                                                                                                    main_type = new FunctionType( Type::Qualifiers(), false ), nullptr )
    56                                 };
     58                std::unique_ptr<FunctionDecl> mainDecl { new FunctionDecl(
     59                        "main",
     60                        DeclarationNode::NoStorageClass,
     61                        LinkageSpec::Cforall,
     62                        main_type = new FunctionType( Type::Qualifiers(), false ),
     63                        nullptr, false, false
     64                ) };
    5765                main_type->get_returnVals().push_back(
    58                         new ObjectDecl( "", DeclarationNode::StorageClasses(), LinkageSpec::Cforall, 0, new BasicType( Type::Qualifiers(), BasicType::SignedInt ), nullptr )
     66                        new ObjectDecl( "", DeclarationNode::NoStorageClass, LinkageSpec::Cforall, 0, new BasicType( Type::Qualifiers(), BasicType::SignedInt ), nullptr )
    5967                );
    6068
    6169                mainDecl->get_functionType()->get_parameters().push_back(
    62                         new ObjectDecl( "", DeclarationNode::StorageClasses(), LinkageSpec::Cforall, 0, new BasicType( Type::Qualifiers(), BasicType::SignedInt ), nullptr )
     70                        new ObjectDecl( "", DeclarationNode::NoStorageClass, LinkageSpec::Cforall, 0, new BasicType( Type::Qualifiers(), BasicType::SignedInt ), nullptr )
    6371                );
    6472
    6573                mainDecl->get_functionType()->get_parameters().push_back(
    66                         new ObjectDecl( "", DeclarationNode::StorageClasses(), LinkageSpec::Cforall, 0,
     74                        new ObjectDecl( "", DeclarationNode::NoStorageClass, LinkageSpec::Cforall, 0,
    6775                        new PointerType( Type::Qualifiers(), new PointerType( Type::Qualifiers(), new BasicType( Type::Qualifiers(), BasicType::Char ) ) ),
    6876                        nullptr )
Note: See TracChangeset for help on using the changeset viewer.