- Notifications
You must be signed in to change notification settings - Fork2
agentcooper/eye
Folders and files
| Name | Name | Last commit message | Last commit date | |
|---|---|---|---|---|
Repository files navigation
🚧 Work in progress 🚧
Eye is a statically typed compiled language implemented using LLVM, with a syntax inspired by TypeScript.
interfaceCounter{inc:()=>i64,reset:()=>void}functionmakeCounter(initialValue:i64):Counter{letcounter=initialValue;letinc=():i64=>{counter=counter+1;returncounter;};letreset=():void=>{counter=0;};return{inc:inc,reset:reset};}functionmain():i64{letcounter=makeCounter(10);letinc=counter.inc;letreset=counter.reset;print(inc());print(inc());reset();print(inc());print(inc());return0;}
Roadmap is available inTODO.md.
make all
Make sure you have LLVM installed.
On macOS 13, I have LLVM installed throughBrew, with following environment variables set:
export PATH="/opt/homebrew/opt/llvm/bin:$PATH"export SDKROOT="$(xcrun --show-sdk-path)"export LIBRARY_PATH="$LIBRARY_PATH:$SDKROOT/usr/lib"export LDFLAGS="-L/opt/homebrew/opt/llvm/lib"export CPPFLAGS="-I/opt/homebrew/opt/llvm/include"
# compile and runmake program SOURCE_FILE=snapshots/closure.eye&& ./program# compile and run (debug)DEBUG=1 make program SOURCE_FILE=snapshots/closure.eye&& ./program
Testing is done by checking the expected change in snapshots.
make snapshot
The name "Eye" is inspired by theIJ bay in Amsterdam.
About
Eye is a statically typed compiled language implemented using LLVM, with a syntax inspired by TypeScript
Topics
Resources
Uh oh!
There was an error while loading.Please reload this page.