Commit 98cc5f9e authored by Sven Gestegård Robertz's avatar Sven Gestegård Robertz
Browse files

Merge branch 'master' of git.cs.lth.se:sven/labcomm-core

parents 58d2417c 318852d7
...@@ -22,9 +22,9 @@ import se.lth.control.labcomm2014.Decoder; ...@@ -22,9 +22,9 @@ import se.lth.control.labcomm2014.Decoder;
import se.lth.control.labcomm2014.DecoderChannel; import se.lth.control.labcomm2014.DecoderChannel;
import se.lth.control.labcomm2014.Encoder; import se.lth.control.labcomm2014.Encoder;
import se.lth.control.labcomm2014.EncoderChannel; import se.lth.control.labcomm2014.EncoderChannel;
import AST.Parser; import se.lth.control.labcomm2014.compiler.LabCommParser;
import AST.Scanner; import se.lth.control.labcomm2014.compiler.LabCommScanner;
import AST.Program; import se.lth.control.labcomm2014.compiler.Program;
import beaver.Parser.Exception; import beaver.Parser.Exception;
public class DynamicPart { public class DynamicPart {
...@@ -160,8 +160,8 @@ public class DynamicPart { ...@@ -160,8 +160,8 @@ public class DynamicPart {
public static InRAMCompiler generateCode(String lcDecl, HashMap<String, String> handlers) { public static InRAMCompiler generateCode(String lcDecl, HashMap<String, String> handlers) {
Program ast = null; Program ast = null;
InputStream in = new ByteArrayInputStream(lcDecl.getBytes()); InputStream in = new ByteArrayInputStream(lcDecl.getBytes());
Scanner scanner = new Scanner(in); LabCommScanner scanner = new LabCommScanner(in);
Parser parser = new Parser(); LabCommParser parser = new LabCommParser();
Collection errors = new LinkedList(); Collection errors = new LinkedList();
InRAMCompiler irc = null; InRAMCompiler irc = null;
...@@ -200,7 +200,7 @@ public class DynamicPart { ...@@ -200,7 +200,7 @@ public class DynamicPart {
private static InRAMCompiler handleAst(Program lcAST, HashMap<String, String> handlers) { private static InRAMCompiler handleAst(Program lcAST, HashMap<String, String> handlers) {
Map<String, String> genCode = new HashMap<String, String>(); Map<String, String> genCode = new HashMap<String, String>();
try { try {
lcAST.J_gen(genCode, "labcomm.generated", 2013); lcAST.J_gen(genCode, "labcomm.generated", 2014);
} catch (IOException e) { } catch (IOException e) {
e.printStackTrace(); e.printStackTrace();
} }
......
...@@ -22,9 +22,9 @@ import se.lth.control.labcomm2014.Decoder; ...@@ -22,9 +22,9 @@ import se.lth.control.labcomm2014.Decoder;
import se.lth.control.labcomm2014.DecoderChannel; import se.lth.control.labcomm2014.DecoderChannel;
import se.lth.control.labcomm2014.Encoder; import se.lth.control.labcomm2014.Encoder;
import se.lth.control.labcomm2014.EncoderChannel; import se.lth.control.labcomm2014.EncoderChannel;
import AST.Parser; import se.lth.control.labcomm2014.compiler.LabCommParser;
import AST.Scanner; import se.lth.control.labcomm2014.compiler.LabCommScanner;
import AST.Program; import se.lth.control.labcomm2014.compiler.Program;
import beaver.Parser.Exception; import beaver.Parser.Exception;
public class TestLabcommGen { public class TestLabcommGen {
...@@ -163,8 +163,8 @@ public class TestLabcommGen { ...@@ -163,8 +163,8 @@ public class TestLabcommGen {
public static InRAMCompiler generateCode(String lcDecl, HashMap<String, String> handlers) { public static InRAMCompiler generateCode(String lcDecl, HashMap<String, String> handlers) {
Program ast = null; Program ast = null;
InputStream in = new ByteArrayInputStream(lcDecl.getBytes()); InputStream in = new ByteArrayInputStream(lcDecl.getBytes());
Scanner scanner = new Scanner(in); LabCommScanner scanner = new LabCommScanner(in);
Parser parser = new Parser(); LabCommParser parser = new LabCommParser();
Collection errors = new LinkedList(); Collection errors = new LinkedList();
InRAMCompiler irc = null; InRAMCompiler irc = null;
...@@ -203,7 +203,7 @@ public class TestLabcommGen { ...@@ -203,7 +203,7 @@ public class TestLabcommGen {
private static InRAMCompiler handleAst(Program lcAST, HashMap<String, String> handlers) { private static InRAMCompiler handleAst(Program lcAST, HashMap<String, String> handlers) {
Map<String, String> genCode = new HashMap<String, String>(); Map<String, String> genCode = new HashMap<String, String>();
try { try {
lcAST.J_gen(genCode, "labcomm.generated", 2013); lcAST.J_gen(genCode, "labcomm.generated", 2014);
} catch (IOException e) { } catch (IOException e) {
e.printStackTrace(); e.printStackTrace();
} }
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment