From 2a609cb942ad35f08cb32fd629b95af489c4a1a4 Mon Sep 17 00:00:00 2001 From: Dave Parker Date: Thu, 16 Feb 2012 13:03:12 +0000 Subject: [PATCH] Better error message for unexpected non-exception. git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@4640 bbc10eb1-c90d-0410-af57-cb519fbb1720 --- prism/src/parser/ast/Property.java | 3 +++ 1 file changed, 3 insertions(+) diff --git a/prism/src/parser/ast/Property.java b/prism/src/parser/ast/Property.java index 3a6eb13d..c6985563 100644 --- a/prism/src/parser/ast/Property.java +++ b/prism/src/parser/ast/Property.java @@ -200,6 +200,9 @@ public class Property extends ASTElement } throw new PrismException("Unexpected error: " + errMsg); } + if (strExpected.startsWith("Error")) { + throw new PrismException("Was expecting an error"); + } // Check expected/actual result Type type = expr.getType();