Changeset 3f80888 for src/CodeGen/CodeGenerator.cc
- Timestamp:
- Mar 6, 2017, 2:07:04 PM (9 years ago)
- Branches:
- ADT, aaron-thesis, arm-eh, ast-experimental, cleanup-dtors, deferred_resn, demangler, enum, forall-pointer-decay, jacob/cs343-translation, jenkins-sandbox, master, new-ast, new-ast-unique-expr, new-env, no_list, persistent-indexer, pthread-emulation, qualifiedEnum, resolv-new, with_gc
- Children:
- 2988eeb
- Parents:
- df47e2f (diff), d107010 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)links above to see all the changes relative to each parent. - File:
-
- 1 edited
-
src/CodeGen/CodeGenerator.cc (modified) (5 diffs)
Legend:
- Unmodified
- Added
- Removed
-
src/CodeGen/CodeGenerator.cc
rdf47e2f r3f80888 10 10 // Created On : Mon May 18 07:44:20 2015 11 11 // Last Modified By : Peter A. Buhr 12 // Last Modified On : Thu Feb 16 14:56:29201713 // Update Count : 4 1812 // Last Modified On : Fri Mar 3 21:18:47 2017 13 // Update Count : 465 14 14 // 15 15 … … 134 134 135 135 handleStorageClass( functionDecl ); 136 if ( functionDecl->get_isInline() ) { 137 output << "inline "; 138 } // if 139 if ( functionDecl->get_isNoreturn() ) { 140 output << "_Noreturn "; 141 } // if 136 DeclarationNode::print_FuncSpec( output, functionDecl->get_funcSpec() ); 137 142 138 output << genType( functionDecl->get_functionType(), mangleName( functionDecl ), pretty ); 143 139 … … 835 831 } 836 832 837 838 833 void CodeGenerator::visit( ReturnStmt * returnStmt ) { 839 834 output << "return "; … … 899 894 } 900 895 901 void CodeGenerator::handleStorageClass( Declaration * decl ) {896 void CodeGenerator::handleStorageClass( DeclarationWithType * decl ) { 902 897 switch ( decl->get_storageClass() ) { 898 //output << DeclarationNode::storageClassNames[decl->get_storageClass()] << ' '; 903 899 case DeclarationNode::Extern: 904 900 output << "extern "; … … 913 909 output << "register "; 914 910 break; 915 case DeclarationNode::Inline:916 output << "inline ";917 break;918 case DeclarationNode::Fortran:919 output << "fortran ";920 break;921 case DeclarationNode::Noreturn:922 output << "_Noreturn ";923 break;924 911 case DeclarationNode::Threadlocal: 925 output << "_Thread_local ";926 break;912 output << "_Thread_local "; 913 break; 927 914 case DeclarationNode::NoStorageClass: 928 915 break; 916 default: 917 assert( false ); 929 918 } // switch 930 } 919 } // CodeGenerator::handleStorageClass 931 920 932 921 std::string genName( DeclarationWithType * decl ) {
Note:
See TracChangeset
for help on using the changeset viewer.