From 73d1ba7a3a4c3c1df4863861cbf71ddf85ccb7d3 Mon Sep 17 00:00:00 2001 From: bculkin2442 Date: Sun, 3 Apr 2016 20:36:27 -0400 Subject: Code maintenance and changes --- BJC-Utils2/src/main/java/bjc/utils/parserutils/TreeConstructor.java | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'BJC-Utils2/src/main/java/bjc/utils/parserutils/TreeConstructor.java') diff --git a/BJC-Utils2/src/main/java/bjc/utils/parserutils/TreeConstructor.java b/BJC-Utils2/src/main/java/bjc/utils/parserutils/TreeConstructor.java index 28ca1e3..6fedf87 100644 --- a/BJC-Utils2/src/main/java/bjc/utils/parserutils/TreeConstructor.java +++ b/BJC-Utils2/src/main/java/bjc/utils/parserutils/TreeConstructor.java @@ -41,7 +41,11 @@ public class TreeConstructor { } else { if (queue.size() < 2) { throw new IllegalStateException( - "Attempted to parse binary operator without enough operands"); + "Attempted to parse binary operator without enough operands.\n" + + "Problem operator is " + + element + + "\nPossible operand is: \n\t" + + queue.peek()); } AST rightAST = queue.pop(); -- cgit v1.2.3