Changeset 321a2481
- Timestamp:
- Jun 6, 2016, 1:11:34 PM (8 years ago)
- Branches:
- ADT, aaron-thesis, arm-eh, ast-experimental, cleanup-dtors, ctor, deferred_resn, demangler, enum, forall-pointer-decay, gc_noraii, 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:
- 64071c2
- Parents:
- b8387fc
- git-author:
- Rob Schluntz <rschlunt@…> (06/06/16 13:08:28)
- git-committer:
- Rob Schluntz <rschlunt@…> (06/06/16 13:11:34)
- Location:
- src
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
src/CodeGen/CodeGenerator.cc
rb8387fc r321a2481 638 638 639 639 void CodeGenerator::visit( ExprStmt *exprStmt ) { 640 // I don't see why this check is necessary.641 // If this starts to cause problems then put it back in,642 // with an explanation643 640 assert( exprStmt ); 644 645 // if ( exprStmt != 0 ) { 646 exprStmt->get_expr()->accept( *this ); 647 output << ";" ; 648 // } // if 641 // cast the top-level expression to void to reduce gcc warnings. 642 Expression * expr = new CastExpr( exprStmt->get_expr() ); 643 expr->accept( *this ); 644 output << ";"; 649 645 } 650 646 … … 755 751 756 752 void CodeGenerator::visit( WhileStmt *whileStmt ) { 757 if ( whileStmt->get_isDoWhile() ) 753 if ( whileStmt->get_isDoWhile() ) { 758 754 output << "do" ; 759 else {755 } else { 760 756 output << "while (" ; 761 757 whileStmt->get_condition()->accept( *this ); … … 781 777 output << "for (;"; 782 778 783 if ( forStmt->get_condition() != 0 ) 779 if ( forStmt->get_condition() != 0 ) { 784 780 forStmt->get_condition()->accept( *this ); 781 } 785 782 output << ";"; 786 783 787 if ( forStmt->get_increment() != 0 ) 788 forStmt->get_increment()->accept( *this ); 784 if ( forStmt->get_increment() != 0 ) { 785 // cast the top-level expression to void to reduce gcc warnings. 786 Expression * expr = new CastExpr( forStmt->get_increment() ); 787 expr->accept( *this ); 788 } 789 789 output << ") "; 790 790 -
src/Makefile.in
rb8387fc r321a2481 414 414 esac; \ 415 415 done; \ 416 echo ' cd $(top_srcdir) && $(AUTOMAKE) -- gnusrc/Makefile'; \416 echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign src/Makefile'; \ 417 417 $(am__cd) $(top_srcdir) && \ 418 $(AUTOMAKE) -- gnusrc/Makefile418 $(AUTOMAKE) --foreign src/Makefile 419 419 .PRECIOUS: Makefile 420 420 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status -
src/driver/Makefile.in
rb8387fc r321a2481 196 196 esac; \ 197 197 done; \ 198 echo ' cd $(top_srcdir) && $(AUTOMAKE) -- gnusrc/driver/Makefile'; \198 echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign src/driver/Makefile'; \ 199 199 $(am__cd) $(top_srcdir) && \ 200 $(AUTOMAKE) -- gnusrc/driver/Makefile200 $(AUTOMAKE) --foreign src/driver/Makefile 201 201 .PRECIOUS: Makefile 202 202 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status -
src/examples/Makefile.in
rb8387fc r321a2481 198 198 esac; \ 199 199 done; \ 200 echo ' cd $(top_srcdir) && $(AUTOMAKE) -- gnusrc/examples/Makefile'; \200 echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign src/examples/Makefile'; \ 201 201 $(am__cd) $(top_srcdir) && \ 202 $(AUTOMAKE) -- gnusrc/examples/Makefile202 $(AUTOMAKE) --foreign src/examples/Makefile 203 203 .PRECIOUS: Makefile 204 204 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status -
src/libcfa/Makefile.in
rb8387fc r321a2481 231 231 esac; \ 232 232 done; \ 233 echo ' cd $(top_srcdir) && $(AUTOMAKE) -- gnusrc/libcfa/Makefile'; \233 echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign src/libcfa/Makefile'; \ 234 234 $(am__cd) $(top_srcdir) && \ 235 $(AUTOMAKE) -- gnusrc/libcfa/Makefile235 $(AUTOMAKE) --foreign src/libcfa/Makefile 236 236 .PRECIOUS: Makefile 237 237 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
Note: See TracChangeset
for help on using the changeset viewer.