We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 33aac3f commit 29370c3Copy full SHA for 29370c3
pyrepl/simple_interact.py
@@ -35,11 +35,13 @@ def check(): # returns False if there is a problem initializing the state
35
return True
36
37
38
-def run_multiline_interactive_console(mainmodule=None):
+def run_multiline_interactive_console(mainmodule=None, future_flags=0):
39
import code
40
import __main__
41
mainmodule = mainmodule or __main__
42
console = code.InteractiveConsole(mainmodule.__dict__, filename='<stdin>')
43
+ if future_flags:
44
+ console.compile.compiler.flags |= future_flags
45
46
def more_lines(unicodetext):
47
# ooh, look at the hack:
0 commit comments