docs: public String createErrorMessage(RecognitionException e)
  	        {
  	        StringBuilder message = new StringBuilder();
  	                message.append( source + ":"+e.line+":"+e.charPositionInLine+" ");
  	                if ( e instanceof MismatchedTokenException ) {
  	                        MismatchedTokenException mte = (MismatchedTokenException)e;
  	                        message.append("mismatched token: "+
  	                                                           e.token+
  	                                                           "; expecting type "+
  	                                                           tokenNames[mte.expecting]);
  	                }
  	                else if ( e instanceof MismatchedTreeNodeException ) {
  	                        MismatchedTreeNodeException mtne = (MismatchedTreeNodeException)e;
  	                        message.append("mismatched tree node: "+
  	                                                           mtne.node+
  	                                                           "; expecting type "+
  	                                                           tokenNames[mtne.expecting]);
  	                }
  	                else if ( e instanceof NoViableAltException ) {
  	                        NoViableAltException nvae = (NoViableAltException)e;
  	            message.append( "Unexpected token '" + e.token.getText() + "'" );
  	                        /*
  	                        message.append("decision=<<"+nvae.grammarDecisionDescription+">>"+
  	                                                           " state "+nvae.stateNumber+
  	                                                           " (decision="+nvae.decisionNumber+
  	                                                           ") no viable alt; token="+
  	                                                           e.token);
  	                                                           */
  	                }
  	                else if ( e instanceof EarlyExitException ) {
  	                        EarlyExitException eee = (EarlyExitException)e;
  	                        message.append("required (...)+ loop (decision="+
  	                                                           eee.decisionNumber+
  	                                                           ") did not match anything; token="+
  	                                                           e.token);
  	                }
  	                else if ( e instanceof MismatchedSetException ) {
  	                        MismatchedSetException mse = (MismatchedSetException)e;
  	                        message.append("mismatched token '"+
  	                                                           e.token+
  	                                                           "' expecting set "+mse.expecting);
  	                }
  	                else if ( e instanceof MismatchedNotSetException ) {
  	                        MismatchedNotSetException mse = (MismatchedNotSetException)e;
  	                        message.append("mismatched token '"+
  	                                                           e.token+
  	                                                           "' expecting set "+mse.expecting);
  	                }
  	                else if ( e instanceof FailedPredicateException ) {
  	                        FailedPredicateException fpe = (FailedPredicateException)e;
  	                        message.append("rule "+fpe.ruleName+" failed predicate: {"+
  	                                                           fpe.predicateText+"}?");
  	        }
  	                   return message.toString();
  	        }