close(reader);
}
}
private static boolean validPartialSentence(BufferedReader bufreader, CompileMode kind, String filename) {
PythonPartialLexer lexer = null;
try {
bufreader.reset();
CharStream cs = new NoCloseReaderStream(bufreader);
lexer = new PythonPartialLexer(cs);
CommonTokenStream tokens = new CommonTokenStream(lexer);
PythonTokenSource indentedSource = new PythonTokenSource(tokens, filename);
tokens = new CommonTokenStream(indentedSource);
PythonPartialParser parser = new PythonPartialParser(tokens);
switch (kind) {