Changeset 32cab5b for src/ResolvExpr/ConversionCost.cc
- Timestamp:
- Apr 17, 2018, 12:01:09 PM (7 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, new-env, no_list, persistent-indexer, pthread-emulation, qualifiedEnum, with_gc
- Children:
- 3265399
- Parents:
- b2fe1c9 (diff), 81bb114 (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/ResolvExpr/ConversionCost.cc
rb2fe1c9 r32cab5b 275 275 // xxx - not positive this is correct, but appears to allow casting int => enum 276 276 cost = Cost::unsafe; 277 } else if ( dynamic_cast< ZeroType* >( dest ) != nullptr || dynamic_cast< OneType* >( dest ) != nullptr ) { 278 cost = Cost::unsafe; 279 } // if 277 } // if 278 // no cases for zero_t/one_t because it should not be possible to convert int, etc. to zero_t/one_t. 280 279 } 281 280 … … 309 308 // assignResult == 0 means Cost::Infinity 310 309 } // if 311 } else if ( dynamic_cast< ZeroType * >( dest ) ) { 312 cost = Cost::unsafe; 310 // case case for zero_t because it should not be possible to convert pointers to zero_t. 313 311 } // if 314 312 }
Note:
See TracChangeset
for help on using the changeset viewer.