aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lllars/chal.lll55
-rw-r--r--lllars/llltranspiler/build.gradle.kts7
-rw-r--r--lllars/llltranspiler/src/main/kotlin/Input.kt12
-rw-r--r--lllars/parser.hs2
4 files changed, 63 insertions, 13 deletions
diff --git a/lllars/chal.lll b/lllars/chal.lll
new file mode 100644
index 0000000..c0dd021
--- /dev/null
+++ b/lllars/chal.lll
@@ -0,0 +1,55 @@
+!!! all rights reserved to lars <3 !!!
+
+12lars89
+13lars8
+16larssral12+sral13
+0lars2
+1lars19
+2larssral0*sral0
+3larssral2*sral1
+22lars114
+25lars1
+@lars
+23larssral23+1
+25larssral25+1
+22larssral22-1
+lars|sral sral22 lars
+31larssral31+20
+31larssral31+30
+31larssral31+10
+31larssral31+10
+31larssral31+16
+36lars1
+37larssral36*1
+38larssral36*10
+39larssral36*100
+40larssral40+sral37
+40larssral40+sral38
+40larssral40+sral39
+100lars3
+101lars16
+102lars23
+103lars25
+104lars31
+105lars40
+@sral
+300larssral200+100
+sral|lars sralsral300 srallars
+8159larssralsralsral300
+200larssral200+1
+larssral lars
+srallars sral
+@srallars
+0larssral40
+0larssral0-2
+1larssral0-32
+8159larssral0
+larssral lars
+8159larssral1
+larssral lars
+8159larssral16
+larssral lars
+8159larssral23
+larssral lars
+8159lars115
+larssral lars
diff --git a/lllars/llltranspiler/build.gradle.kts b/lllars/llltranspiler/build.gradle.kts
index b8ecb0c..bcb9281 100644
--- a/lllars/llltranspiler/build.gradle.kts
+++ b/lllars/llltranspiler/build.gradle.kts
@@ -1,3 +1,4 @@
+
plugins {
kotlin("jvm") version "2.1.0"
kotlin("plugin.serialization") version "2.1.0"
@@ -6,6 +7,12 @@ plugins {
group = "me.any"
version = "1.0-SNAPSHOT"
+tasks.withType<Jar> {
+ manifest {
+ attributes["Main-Class"] = "me.any.Main"
+ }
+}
+
repositories {
mavenCentral()
}
diff --git a/lllars/llltranspiler/src/main/kotlin/Input.kt b/lllars/llltranspiler/src/main/kotlin/Input.kt
deleted file mode 100644
index 338c37d..0000000
--- a/lllars/llltranspiler/src/main/kotlin/Input.kt
+++ /dev/null
@@ -1,12 +0,0 @@
-package me.any
-
-
-
-
-const val INPUT = """
- {
- "instructions": [{ "comment": " erster kommentar" },{ "comment": " zweite Kommentar" },{ "comment": " dritter Kommentar" },{ "label": "lars" },{ "goto": "lars" },{ "comment": "/sral 0 @lars" },{ "write": { "target": 0, "source": { "access": { "address": 10 } } }},{ "write": { "target": 0, "source": { "binaryOperation": { "a": { "sAddress": { "sAddress": { "address": 10 } } }, "op": "ADD", "b": { "address": 5 } }} }}]
-
-}
-
-""" \ No newline at end of file
diff --git a/lllars/parser.hs b/lllars/parser.hs
index bb3afc2..dfee007 100644
--- a/lllars/parser.hs
+++ b/lllars/parser.hs
@@ -126,7 +126,7 @@ program = license *> sepEndBy instr (some $ char '\n')
main :: IO ()
main = do
- f <- readFile "fac.lll"
+ f <- readFile "chal.lll"
case runParser (program <* many (char '\n') <* eof) "" f of
Right ps ->
putStrLn