Changeset 7527e63 for src/main.cc
- Timestamp:
- Aug 16, 2016, 3:20:06 PM (9 years ago)
- Branches:
- ADT, aaron-thesis, arm-eh, ast-experimental, cleanup-dtors, ctor, deferred_resn, demangler, enum, forall-pointer-decay, jacob/cs343-translation, jenkins-sandbox, master, memory, new-ast, new-ast-unique-expr, new-env, no_list, persistent-indexer, pthread-emulation, qualifiedEnum, resolv-new, with_gc
- Children:
- 1f6d4624
- Parents:
- 950f7a7 (diff), 7880579 (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
Legend:
- Unmodified
- Added
- Removed
-
src/main.cc
r950f7a7 r7527e63 10 10 // Created On : Fri May 15 23:12:02 2015 11 11 // Last Modified By : Peter A. Buhr 12 // Last Modified On : Tue Jul 5 15:23:11201613 // Update Count : 2 0912 // Last Modified On : Mon Aug 15 17:58:57 2016 13 // Update Count : 220 14 14 // 15 15 16 16 #include <iostream> 17 17 #include <fstream> 18 #include <cstdlib>19 #include <cstdio>20 18 #include <getopt.h> 21 19 #include "Parser/Parser.h" 22 #include "Parser/ParseNode.h"23 #include "Parser/LinkageSpec.h"24 20 #include "SynTree/Declaration.h" 25 21 #include "SynTree/Visitor.h" … … 28 24 #include "GenPoly/Box.h" 29 25 #include "GenPoly/CopyParams.h" 26 #include "GenPoly/InstantiateGeneric.h" 30 27 #include "CodeGen/Generate.h" 31 28 #include "CodeGen/FixNames.h" … … 42 39 #include "InitTweak/GenInit.h" 43 40 #include "InitTweak/FixInit.h" 44 #include "InitTweak/FixGlobalInit.h"45 //#include "Explain/GenProlog.h"46 //#include "Try/Visit.h"47 41 48 42 #include "Common/SemanticError.h" … … 193 187 input = fopen( argv[ optind ], "r" ); 194 188 if ( ! input ) { 195 std::cout << "Error: can 't open " << argv[ optind ] << std::endl;189 std::cout << "Error: cannot open " << argv[ optind ] << std::endl; 196 190 exit( EXIT_FAILURE ); 197 191 } // if … … 219 213 FILE * builtins = fopen( libcfap | treep ? "builtins.cf" : CFA_LIBDIR "/builtins.cf", "r" ); 220 214 if ( builtins == NULL ) { 221 std::cerr << "Error: can 't open builtins.cf" << std::endl;215 std::cerr << "Error: cannot open builtins.cf" << std::endl; 222 216 exit( EXIT_FAILURE ); 223 217 } // if … … 227 221 FILE * extras = fopen( libcfap | treep ? "extras.cf" : CFA_LIBDIR "/extras.cf", "r" ); 228 222 if ( extras == NULL ) { 229 std::cerr << "Error: can 't open extras.cf" << std::endl;223 std::cerr << "Error: cannot open extras.cf" << std::endl; 230 224 exit( EXIT_FAILURE ); 231 225 } // if … … 236 230 FILE * prelude = fopen( treep ? "prelude.cf" : CFA_LIBDIR "/prelude.cf", "r" ); 237 231 if ( prelude == NULL ) { 238 std::cerr << "Error: can 't open prelude.cf" << std::endl;232 std::cerr << "Error: cannot open prelude.cf" << std::endl; 239 233 exit( EXIT_FAILURE ); 240 234 } // if … … 282 276 OPTPRINT( "fixNames" ) 283 277 CodeGen::fixNames( translationUnit ); 284 OPTPRINT( "fixGlobalInit" );285 InitTweak::fixGlobalInit( translationUnit, filename, libcfap || treep );286 278 OPTPRINT( "tweakInit" ) 287 279 InitTweak::genInit( translationUnit ); … … 304 296 } 305 297 298 // fix ObjectDecl - replaces ConstructorInit nodes 306 299 OPTPRINT( "fixInit" ) 307 // fix ObjectDecl - replaces ConstructorInit nodes 308 InitTweak::fix( translationUnit ); 300 InitTweak::fix( translationUnit, filename, libcfap || treep ); 309 301 if ( ctorinitp ) { 310 302 dump ( translationUnit ); … … 312 304 } 313 305 306 OPTPRINT("instantiateGenerics") 307 GenPoly::instantiateGeneric( translationUnit ); 314 308 OPTPRINT( "copyParams" ); 315 309 GenPoly::copyParams( translationUnit ); … … 384 378 std::list< Declaration * > decls; 385 379 if ( noprotop ) { 386 filter( translationUnit.begin(), translationUnit.end(), 387 std::back_inserter( decls ), notPrelude ); 380 filter( translationUnit.begin(), translationUnit.end(), std::back_inserter( decls ), notPrelude ); 388 381 } else { 389 382 decls = translationUnit;
Note:
See TracChangeset
for help on using the changeset viewer.