Mercurial > hg > truffle
diff graal/com.oracle.truffle.sl/src/com/oracle/truffle/sl/factory/SLContextFactory.java @ 18485:e3c95cbbb50c
Truffle Instrumentation: major API revision, based around the Probe and Instrument classes; add Instrumentable API for language implementors, with most details automated; reimplemented to handle AST splitting automatically; more JUnit tests.
author | Michael Van De Vanter <michael.van.de.vanter@oracle.com> |
---|---|
date | Sun, 23 Nov 2014 16:07:23 -0800 |
parents | 7661cc464239 |
children | 286aef83a9a7 |
line wrap: on
line diff
--- a/graal/com.oracle.truffle.sl/src/com/oracle/truffle/sl/factory/SLContextFactory.java Fri Nov 21 13:16:02 2014 +0100 +++ b/graal/com.oracle.truffle.sl/src/com/oracle/truffle/sl/factory/SLContextFactory.java Sun Nov 23 16:07:23 2014 -0800 @@ -30,12 +30,14 @@ public final class SLContextFactory { private SLContextFactory() { - } public static SLContext create() { - final SLContext slContext = new SLContext(new BufferedReader(new InputStreamReader(System.in)), System.out); - slContext.initialize(); + return create(new BufferedReader(new InputStreamReader(System.in)), System.out); + } + + public static SLContext create(BufferedReader input, PrintStream output) { + final SLContext slContext = new SLContext(input, output); slContext.setVisualizer(new SLDefaultVisualizer()); return slContext; }