You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on May 18, 2019. It is now read-only.
res := ("Failed to scan top of input: "+ topTokenStr(tokens) +"\n Expected one of: "+ (if listEmpty(expected) then "<EOF>"else stringDelimitList(list(tokenIdStr(id) for id in expected), ", ")) +"\n")::{};
2752
+
res := ("Failed to scan top of input: "+(ifdebug then debugTokenStr(tokens) elsetopTokenStr(tokens)) +"\n Expected one of: "+ (if listEmpty(expected) then "<EOF>"else stringDelimitList(list(tokenIdStr(id) for id in expected), ", ")) +"\n")::{};
2748
2753
res := (" Current parse tree is:\n"+ parseTreeStr(listReverse(tree)) +"\n The parser stack is:\n")::res;
2749
2754
StackOverflow.setStacktraceMessages(0, 100);
2750
2755
for s inStackOverflow.readableStacktraceMessages() loop
@@ -2865,6 +2870,13 @@ algorithm
2865
2870
str := (match tokens case (t as LexerModelicaDiff.TOKEN(id=id))::_ then String(id)+" ("+tokenContent(t)+")"; else"EOF"; end match);
2866
2871
end topTokenStr;
2867
2872
2873
+
function debugTokenStr
2874
+
input list<Token> tokens;
2875
+
output String str;
2876
+
algorithm
2877
+
str := stringDelimitList(list(String(t.id)+" ("+tokenContent(t)+")"for t in tokens), "\n");
0 commit comments