Changeset e3e16bc for src/SynTree/TupleExpr.cc
- Timestamp:
- Sep 13, 2017, 2:34:55 PM (6 years ago)
- Branches:
- aaron-thesis, arm-eh, 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, resolv-new, with_gc
- Children:
- 982832e
- Parents:
- 9f5ecf5
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/SynTree/TupleExpr.cc
r9f5ecf5 re3e16bc 14 14 // 15 15 16 #include <cassert> // for assert, s afe_dynamic_cast, assertf16 #include <cassert> // for assert, strict_dynamic_cast, assertf 17 17 #include <iterator> // for next 18 18 #include <list> // for list, _List_iterator … … 64 64 65 65 TupleIndexExpr::TupleIndexExpr( Expression * tuple, unsigned int index ) : tuple( tuple ), index( index ) { 66 TupleType * type = s afe_dynamic_cast< TupleType * >( tuple->get_result() );66 TupleType * type = strict_dynamic_cast< TupleType * >( tuple->get_result() ); 67 67 assertf( type->size() > index, "TupleIndexExpr index out of bounds: tuple size %d, requested index %d in expr %s", type->size(), index, toString( tuple ).c_str() ); 68 68 set_result( (*std::next( type->get_types().begin(), index ))->clone() );
Note: See TracChangeset
for help on using the changeset viewer.