diff --git a/.gitignore b/.gitignore index c52fdba7636564582fc6cedb7db09213c0e99281..12a510753ad22d0f5d0e9da3a85dcea302fcc0ec 100644 --- a/.gitignore +++ b/.gitignore @@ -7,6 +7,6 @@ /.settings /bin/ /ant-bin/ -/compiler.jar +/relast-compiler.jar /src/generated/ /.gradle diff --git a/README.md b/README.md new file mode 100644 index 0000000000000000000000000000000000000000..dd28cff2df17f5e9daed9540042a91cdeacf6515 --- /dev/null +++ b/README.md @@ -0,0 +1,17 @@ +# RelAST Preprocessor + +Run preprocessor on train benchmark (output written to standard output) + + $ ant jar + $ java -jar relast-compiler.jar examples/TrainBenchmark.relast + +Run preprocessor and write to files + + $ java -jar relast-compiler.jar examples/TrainBenchmark.relast --file + $ cat examples/TrainBenchmarkGen.ast + $ cat examples/TrainBenchmarkGen.jadd + +Run test cases + + $ cd test + $ make \ No newline at end of file diff --git a/build.xml b/build.xml index a35cb9455facd700951bed986451fd0bb9012cf4..50520f7b89ae25fd1839b33e376ed22b3d6ffee0 100755 --- a/build.xml +++ b/build.xml @@ -6,7 +6,7 @@ <property name="tools" value="${basedir}/tools"/> <property name="test-reports.dir" location="report-tests"/> - <property name="jarfile" value="compiler.jar" /> + <property name="jarfile" value="relast-compiler.jar" /> <property name="junitjar" value="${tools}/junit-4.11-SNAPSHOT.jar" /> <!-- "package" is the directory where generated files will be stored --> diff --git a/examples/Rail.relast b/examples/TrainBenchmark.relast similarity index 100% rename from examples/Rail.relast rename to examples/TrainBenchmark.relast diff --git a/spec/scanner/RelAst.flex b/spec/scanner/RelAst.flex index 2039600619b4753d34c42663d3e1260de306f1d7..1e4001989901e5377c152a9a0933fe136a7ff20a 100644 --- a/spec/scanner/RelAst.flex +++ b/spec/scanner/RelAst.flex @@ -41,9 +41,6 @@ EndOfLineComment = "//" [^\n|\r|\r\n]* Comment = {TraditionalComment} | {EndOfLineComment} ID = [a-zA-Z$][a-zA-Z0-9$_]* -FLOAT = -?[0-9]+ \. [0-9]+ {Exponent}? -Exponent = [eE] [+-]? [0-9]+ -NUM = -?[0-9]+ %state STRING diff --git a/test/Test.java b/test/Test.java index fe6be7882cba6f9fda9bcb08496fd6b5933d3c37..1d1a1d7233cdbeea11fec5560be5dd7a327fe715 100644 --- a/test/Test.java +++ b/test/Test.java @@ -28,6 +28,8 @@ public class Test { testBi7(); testBi8(); testBi9(); + + System.out.println("TESTS OK"); } /**