From c4a3a7bbe553e2b1adaeb845dc9e675ccdfd6fdb Mon Sep 17 00:00:00 2001 From: John Wiegley Date: Sun, 17 Jul 2011 15:28:11 -0500 Subject: Changed an assert into a proper exception --- src/op.cc | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'src/op.cc') diff --git a/src/op.cc b/src/op.cc index 3876784d..4baac811 100644 --- a/src/op.cc +++ b/src/op.cc @@ -421,10 +421,8 @@ value_t expr_t::op_t::calc(scope_t& scope, ptr_op_t * locus, const int depth) break; } - case LAST: default: - assert(false); - break; + throw_(calc_error, _("Unexpected expr node '%1'") << op_context(this)); } #if defined(DEBUG_ON) -- cgit v1.2.3