Changes in src/GenPoly/Specialize.cc [fea7ca7:d3b7937]
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/GenPoly/Specialize.cc
rfea7ca7 rd3b7937 10 10 // Created On : Mon May 18 07:44:20 2015 11 11 // Last Modified By : Rob Schluntz 12 // Last Modified On : Thu Apr 28 15:17:45201613 // Update Count : 2412 // Last Modified On : Wed Jan 20 12:40:33 2016 13 // Update Count : 18 14 14 // 15 15 … … 41 41 virtual Expression * mutate( AddressExpr *castExpr ); 42 42 virtual Expression * mutate( CastExpr *castExpr ); 43 //virtual Expression * mutate( LogicalExpr *logicalExpr );44 //virtual Expression * mutate( ConditionalExpr *conditionalExpr );45 //virtual Expression * mutate( CommaExpr *commaExpr );43 virtual Expression * mutate( LogicalExpr *logicalExpr ); 44 virtual Expression * mutate( ConditionalExpr *conditionalExpr ); 45 virtual Expression * mutate( CommaExpr *commaExpr ); 46 46 47 47 private: … … 142 142 143 143 Expression * Specialize::doSpecialization( Type *formalType, Expression *actual, InferredParams *inferParams ) { 144 assert( ! actual->get_results().empty() ); // using front, should have this assert144 assert( ! actual->get_results().empty() ); 145 145 if ( needsSpecialization( formalType, actual->get_results().front(), env ) ) { 146 146 FunctionType *funType; … … 212 212 } 213 213 214 // Removing these for now. Richard put these in for some reason, but it's not clear why. 215 // In particular, copy constructors produce a comma expression, and with this code the parts 216 // of that comma expression are not specialized, which causes problems. 217 218 // Expression * Specialize::mutate( LogicalExpr *logicalExpr ) { 219 // return logicalExpr; 220 // } 221 222 // Expression * Specialize::mutate( ConditionalExpr *condExpr ) { 223 // return condExpr; 224 // } 225 226 // Expression * Specialize::mutate( CommaExpr *commaExpr ) { 227 // return commaExpr; 228 // } 214 Expression * Specialize::mutate( LogicalExpr *logicalExpr ) { 215 return logicalExpr; 216 } 217 218 Expression * Specialize::mutate( ConditionalExpr *condExpr ) { 219 return condExpr; 220 } 221 222 Expression * Specialize::mutate( CommaExpr *commaExpr ) { 223 return commaExpr; 224 } 229 225 } // namespace GenPoly 230 226
Note: See TracChangeset
for help on using the changeset viewer.