Skip to content

Commit

Permalink
Return original expr instead of throwing errors to past test
Browse files Browse the repository at this point in the history
  • Loading branch information
perry0513 authored and polgreen committed Mar 19, 2024
1 parent f401a7e commit 837bee8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/main/scala/uclid/smt/ASTConcreteEvaluator.scala
Original file line number Diff line number Diff line change
Expand Up @@ -40,14 +40,14 @@ object ASTConcreteEvaluator
case _ => throw new Utils.UnimplementedException("Unimplemented operator application evaluation")
}
}
case _ => throw new Utils.UnimplementedException("Unimplemented operator application evaluation")
case _ => e // Unimplemented operator application evaluation
}
}
case ConstRecord(fields) => ConstRecord(fields)
case Symbol(id, typ) => {
val definitions = modelUclid.functions.filter(fun => fun._1.asInstanceOf[lang.DefineDecl].id.name == id.toString)
definitions.size match {
case 0 => throw new Utils.RuntimeError("No definition found in the assignment model!")
case 0 => e // No definition found, return the symbol. Should raise some error here
case 1 => {
val valueExpr = definitions.head._1.asInstanceOf[lang.DefineDecl].expr
Converter.exprToSMT(valueExpr, lang.Scope.empty)
Expand Down

0 comments on commit 837bee8

Please sign in to comment.