- Timestamp:
- May 8, 2020, 4:44:53 PM (5 years ago)
- Branches:
- ADT, arm-eh, ast-experimental, enum, forall-pointer-decay, jacob/cs343-translation, master, new-ast, new-ast-unique-expr, pthread-emulation, qualifiedEnum
- Children:
- 5c9b20c
- Parents:
- e3bc51c (diff), 0e7e3c17 (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. - Location:
- src
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
src/CompilationState.cc
re3bc51c rbcd74f3 27 27 nopreludep = false, 28 28 genproto = false, 29 deterministic_output = false, 29 30 nomainp = false, 30 31 parsep = false, -
src/CompilationState.h
re3bc51c rbcd74f3 28 28 nopreludep, 29 29 genproto, 30 deterministic_output, 30 31 nomainp, 31 32 parsep, -
src/Parser/parser.yy
re3bc51c rbcd74f3 10 10 // Created On : Sat Sep 1 20:22:55 2001 11 11 // Last Modified By : Peter A. Buhr 12 // Last Modified On : Fri Mar 6 17:26:45202013 // Update Count : 44 7412 // Last Modified On : Mon Apr 27 12:25:42 2020 13 // Update Count : 4483 14 14 // 15 15 … … 966 966 967 967 tuple_expression_list: 968 assignment_expression_opt 969 | tuple_expression_list ',' assignment_expression_opt 968 assignment_expression 969 | '@' // CFA 970 { SemanticError( yylloc, "Eliding tuple element with '@' is currently unimplemented." ); $$ = nullptr; } 971 | tuple_expression_list ',' assignment_expression 970 972 { $$ = (ExpressionNode *)($1->set_last( $3 )); } 973 | tuple_expression_list ',' '@' 974 { SemanticError( yylloc, "Eliding tuple element with '@' is currently unimplemented." ); $$ = nullptr; } 971 975 ; 972 976 -
src/ResolvExpr/TypeEnvironment.cc
re3bc51c rbcd74f3 20 20 #include <utility> // for pair, move 21 21 22 #include "CompilationState.h" // for deterministic_output 22 23 #include "Common/utility.h" // for maybeClone 23 24 #include "SynTree/Type.h" // for Type, FunctionType, Type::Fora... … … 106 107 107 108 void EqvClass::print( std::ostream &os, Indenter indent ) const { 108 os << "( "; 109 std::copy( vars.begin(), vars.end(), std::ostream_iterator< std::string >( os, " " ) ); 110 os << ")"; 109 if( !deterministic_output ) { 110 os << "( "; 111 std::copy( vars.begin(), vars.end(), std::ostream_iterator< std::string >( os, " " ) ); 112 os << ")"; 113 } 111 114 if ( type ) { 112 115 os << " -> "; … … 235 238 // check safely bindable 236 239 if ( r.type && occursIn( r.type, s.vars.begin(), s.vars.end(), *this ) ) return false; 237 240 238 241 // merge classes in 239 242 r.vars.insert( s.vars.begin(), s.vars.end() ); -
src/main.cc
re3bc51c rbcd74f3 449 449 450 450 451 static const char optstring[] = ":c:ghlLmNnp P:S:twW:D:";451 static const char optstring[] = ":c:ghlLmNnpdP:S:twW:D:"; 452 452 453 453 enum { PreludeDir = 128 }; … … 462 462 { "no-prelude", no_argument, nullptr, 'n' }, 463 463 { "prototypes", no_argument, nullptr, 'p' }, 464 { "deterministic-out", no_argument, nullptr, 'd' }, 464 465 { "print", required_argument, nullptr, 'P' }, 465 466 { "prelude-dir", required_argument, nullptr, PreludeDir }, … … 482 483 "do not read prelude", // -n 483 484 "generate prototypes for prelude functions", // -p 485 "don't print output that isn't deterministic", // -d 484 486 "print", // -P 485 487 "<directory> prelude directory for debug/nodebug", // no flag … … 586 588 genproto = true; 587 589 break; 590 case 'd': // don't print non-deterministic output 591 deterministic_output = true; 592 break; 588 593 case 'P': // print options 589 594 for ( int i = 0;; i += 1 ) {
Note: See TracChangeset
for help on using the changeset viewer.