IDK
This commit is contained in:
4
playground/.gitignore
vendored
Normal file
4
playground/.gitignore
vendored
Normal file
@@ -0,0 +1,4 @@
|
||||
/*
|
||||
!/.gitignore
|
||||
!/*.mcl
|
||||
!/mclangc
|
||||
13
playground/mclangc
Executable file
13
playground/mclangc
Executable file
@@ -0,0 +1,13 @@
|
||||
#!/usr/bin/bash
|
||||
|
||||
#? This is just a passthrough for the compiled mclangc binary for ease of use
|
||||
#? It also compiles mclangc every time its ran
|
||||
|
||||
pushd ../ > /dev/null
|
||||
|
||||
cargo build --release -q
|
||||
|
||||
popd > /dev/null
|
||||
|
||||
|
||||
../target/release/mclangc -I../include ${@:1}
|
||||
35
playground/test.mcl
Normal file
35
playground/test.mcl
Normal file
@@ -0,0 +1,35 @@
|
||||
include "std.mcl"
|
||||
|
||||
|
||||
struct StatDef do
|
||||
val -> u32
|
||||
val2 -> i8
|
||||
end
|
||||
|
||||
alloc Stat StatDef end
|
||||
|
||||
fn main with int ptr returns void then
|
||||
// p l
|
||||
"Hello!\n" puts
|
||||
|
||||
Stat.val 69 write32
|
||||
|
||||
Stat.val read32 _dbg_print
|
||||
Stat.__size read32 _dbg_print
|
||||
|
||||
// memory fd 4 end
|
||||
|
||||
// NULL
|
||||
// FS_O_RDWR
|
||||
// c"/home/mcorange/@Projects/rust/programming_languages/mclang/mclangc/playground/test.mcl"
|
||||
// fopen
|
||||
// dup _dbg_print
|
||||
// fd swap write32
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
done
|
||||
Reference in New Issue
Block a user