Created
May 31, 2023 07:20
-
-
Save zaidmukaddam/1f90ed8e9ef3ad6fc7903f0dcd873551 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Robot : type { | |
name :: Text | |
} | |
[context] | |
robot :: Robot | |
robot : crash "`robot` not initialized" | |
with-robot : syntax { | |
with-robot 'name 'body -> with (robot : Robot { name : 'name }) 'body | |
} | |
say-hello : syntax { | |
say-hello -> show (format "Hello, I'm _!" (name of robot)) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment