- Timestamp:
- Jul 30, 2018, 4:43:48 PM (6 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, no_list, persistent-indexer, pthread-emulation, qualifiedEnum
- Children:
- 5cbacf1
- Parents:
- fd2debf
- git-author:
- Rob Schluntz <rschlunt@…> (07/30/18 15:38:10)
- git-committer:
- Rob Schluntz <rschlunt@…> (07/30/18 16:43:48)
- Location:
- src
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
src/CompilationState.cc
rfd2debf r05e6eb5 39 39 linemarks = false; 40 40 41 // bootstrapping:42 // libcfap || treep43 44 41 // Local Variables: // 45 42 // tab-width: 4 // -
src/CompilationState.h
rfd2debf r05e6eb5 40 40 linemarks; 41 41 42 42 // is the compiler building prelude or libcfa? 43 inline bool buildingLibrary() { 44 return libcfap | treep; 45 } 43 46 44 47 // Local Variables: // -
src/Validate/HandleAttributes.cc
rfd2debf r05e6eb5 117 117 std::string name = attr->normalizedName(); 118 118 if (name == "init_priority") { 119 119 // TODO: implement C++-like init_priority attribute 120 120 } 121 121 } … … 139 139 SemanticWarning(attr->location, Warning::GccAttributes, 140 140 toCString( name, " priorities from 0 to 100 are reserved for the implementation" ) ); 141 } else if (priority < 201 ) {141 } else if (priority < 201 && ! buildingLibrary()) { 142 142 SemanticWarning(attr->location, Warning::GccAttributes, 143 143 toCString( name, " priorities from 101 to 200 are reserved for the implementation" ) ); -
src/main.cc
rfd2debf r05e6eb5 183 183 184 184 // Read to gcc builtins, if not generating the cfa library 185 FILE * gcc_builtins = fopen( libcfap | treep? "../prelude/gcc-builtins.cf" : CFA_LIBDIR "/gcc-builtins.cf", "r" );185 FILE * gcc_builtins = fopen( buildingLibrary() ? "../prelude/gcc-builtins.cf" : CFA_LIBDIR "/gcc-builtins.cf", "r" ); 186 186 assertf( gcc_builtins, "cannot open gcc-builtins.cf\n" ); 187 187 parse( gcc_builtins, LinkageSpec::Compiler ); 188 188 189 189 // read the extra prelude in, if not generating the cfa library 190 FILE * extras = fopen( libcfap | treep? "../prelude/extras.cf" : CFA_LIBDIR "/extras.cf", "r" );190 FILE * extras = fopen( buildingLibrary() ? "../prelude/extras.cf" : CFA_LIBDIR "/extras.cf", "r" ); 191 191 assertf( extras, "cannot open extras.cf\n" ); 192 192 parse( extras, LinkageSpec::BuiltinC ); … … 194 194 if ( ! libcfap ) { 195 195 // read the prelude in, if not generating the cfa library 196 FILE * prelude = fopen( treep? "../prelude/prelude.cf" : CFA_LIBDIR "/prelude.cf", "r" );196 FILE * prelude = fopen( buildingLibrary() ? "../prelude/prelude.cf" : CFA_LIBDIR "/prelude.cf", "r" ); 197 197 assertf( prelude, "cannot open prelude.cf\n" ); 198 198 parse( prelude, LinkageSpec::Intrinsic ); 199 199 200 200 // Read to cfa builtins, if not generating the cfa library 201 FILE * builtins = fopen( libcfap | treep? "../prelude/builtins.cf" : CFA_LIBDIR "/builtins.cf", "r" );201 FILE * builtins = fopen( buildingLibrary() ? "../prelude/builtins.cf" : CFA_LIBDIR "/builtins.cf", "r" ); 202 202 assertf( builtins, "cannot open builtins.cf\n" ); 203 203 parse( builtins, LinkageSpec::BuiltinCFA ); … … 274 274 275 275 // fix ObjectDecl - replaces ConstructorInit nodes 276 PASS( "fixInit", InitTweak::fix( translationUnit, libcfap || treep) );276 PASS( "fixInit", InitTweak::fix( translationUnit, buildingLibrary() ) ); 277 277 if ( ctorinitp ) { 278 278 dump ( translationUnit );
Note: See TracChangeset
for help on using the changeset viewer.