docs: private AstNode nameOrLabel()
          throws IOException
      {
          if (currentToken != Token.NAME) throw codeBug();
          int pos = ts.tokenBeg;
  
          // set check for label and call down to primaryExpr
          currentFlaggedToken |= TI_CHECK_LABEL;
          AstNode expr = expr();
  
          if (expr.getType() != Token.LABEL) {
              AstNode n = new ExpressionStatement(expr, !insideFunction());
              n.lineno = expr.lineno;
              return n;
          }
  
          LabeledStatement bundle = new LabeledStatement(pos);
          recordLabel((Label)expr, bundle);
          bundle.setLineno(ts.lineno);
          // look for more labels
          AstNode stmt = null;
          while (peekToken() == Token.NAME) {
              currentFlaggedToken |= TI_CHECK_LABEL;
              expr = expr();
              if (expr.getType() != Token.LABEL) {
                  stmt = new ExpressionStatement(expr, !insideFunction());
                  autoInsertSemicolon(stmt);
                  break;
              }
              recordLabel((Label)expr, bundle);
          }
  
          // no more labels; now parse the labeled statement
          try {
              currentLabel = bundle;
              if (stmt == null) {
                  stmt = statementHelper();
                  int ntt = peekToken();
                  if(ntt == Token.COMMENT && stmt.getLineno() == scannedComments.get(scannedComments.size()-1).getLineno()) {
                      stmt.setInlineComment(scannedComments.get(scannedComments.size() - 1));
                      consumeToken();
                  }
              }
          } finally {
              currentLabel = null;
              // remove the labels for this statement from the global set
              for (Label lb : bundle.getLabels()) {
                  labelSet.remove(lb.getName());
              }
          }
  
          // If stmt has parent assigned its position already is relative
          // (See bug #710225)
          bundle.setLength(stmt.getParent() == null
                       ? getNodeEnd(stmt) - pos
                       : getNodeEnd(stmt));
          bundle.setStatement(stmt);
          return bundle;
      }