Skip to content

Instantly share code, notes, and snippets.

@frame-lang
Created July 29, 2021 01:07
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save frame-lang/6cd28bf4815d58ad2a6d2aa7f3dfed97 to your computer and use it in GitHub Desktop.
Save frame-lang/6cd28bf4815d58ad2a6d2aa7f3dfed97 to your computer and use it in GitHub Desktop.
An internal iterator
#Iterator
-interface-
start @(|>>|)
-machine-
$Start
|>>|
-> $Dec ^
$Dec
|>|
i = i - 1
i == 0 ?
-> $End ^
:
-> $Print ^
:: ^
$Print
|>|
print(i)
-> $Dec ^
$End
|>|
print("done") ^
-actions-
print[msg:String]
-domain-
var i:int = 5
##
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment