void (SyntaxTreeBuilder.Marker endMarker, boolean async) { if (myBuilder.getTokenType() == PyTokenTypes.DEF_KEYWORD) { parseFunctionInnards(endMarker, async); } else if (myBuilder.getTokenType() == PyTokenTypes.CLASS_KEYWORD) { getStatementParser().parseClassDeclaration(endMarker); } else { myBuilder.error(message("PARSE.expected.@.or.def")); SyntaxTreeBuilder.Marker parameterList = myBuilder.mark(); // To have non-empty parameters list at all the time. parameterList.done(PyElementTypes.PARAMETER_LIST); myBuilder.mark().done(PyElementTypes.STATEMENT_LIST); // To have non-empty empty statement list endMarker.done(getFunctionType()); } }