Author: ruschein
Date: 2010-09-28 12:38:33 -0700 (Tue, 28 Sep 2010)
New Revision: 22090
Modified:
cytoscape/trunk/corelibs/equations/src/main/java/org/cytoscape/equations/EqnParserImpl.java
Log:
Slight improvement in error reporting.
Modified:
cytoscape/trunk/corelibs/equations/src/main/java/org/cytoscape/equations/EqnParserImpl.java
===================================================================
---
cytoscape/trunk/corelibs/equations/src/main/java/org/cytoscape/equations/EqnParserImpl.java
2010-09-28 18:20:44 UTC (rev 22089)
+++
cytoscape/trunk/corelibs/equations/src/main/java/org/cytoscape/equations/EqnParserImpl.java
2010-09-28 19:38:33 UTC (rev 22090)
@@ -314,7 +314,8 @@
if (token != Token.IDENTIFIER)
throw new IllegalStateException(functionNameStartPos +
": function name expected!");
- final String functionNameCandidate =
tokeniser.getIdent().toUpperCase();
+ final String originalName = tokeniser.getIdent();
+ final String functionNameCandidate = originalName.toUpperCase();
if (functionNameCandidate.equals("DEFINED"))
return parseDefined();
@@ -322,10 +323,10 @@
if (func == null) {
if (tokeniser.getToken() == Token.OPEN_PAREN)
throw new
IllegalStateException(functionNameStartPos + ": call to unknown function "
- +
functionNameCandidate + "()!");
+ + originalName
+ "()!");
else
throw new
IllegalStateException(functionNameStartPos + ": unknown text \""
- +
functionNameCandidate + "\", maybe you forgot to put quotes around this text?");
+ + originalName
+ "\", maybe you forgot to put quotes around this text?");
}
token = tokeniser.getToken();
--
You received this message because you are subscribed to the Google Groups
"cytoscape-cvs" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/cytoscape-cvs?hl=en.