Differences
This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision | ||
language [2018/11/02 13:15] 127.0.0.1 external edit |
language [2019/09/13 09:55] (current) |
||
---|---|---|---|
Line 1: | Line 1: | ||
#+options: toc:nil | #+options: toc:nil | ||
+ | #+html: {{tag>language syntax}} | ||
* Language | * Language | ||
Line 30: | Line 31: | ||
CASM does not require any newlines, tabulators, or statement separators like in other specification or programming languages. | CASM does not require any newlines, tabulators, or statement separators like in other specification or programming languages. | ||
- | As example the following /Hello World/ application is equivalent to the one given above. | ||
- | #+html: <callout type="info" icon="fa fa-code"> | ||
- | The inline version of the /Hello World/ application specified in CASM: | ||
- | #+begin_src casm | ||
- | CASM init HelloWorld rule HelloWorld println( "Hello world!" ) | ||
- | #+end_src | ||
- | #+html: </callout> | ||
TBA | TBA | ||
Line 44: | Line 38: | ||
TBA | TBA | ||
+ | |||
+ | # #+html: <callout type="info" icon="fa fa-code"> | ||
+ | # The following example defines a binary function named =phoneBook= with a | ||
+ | # given type relation $x : String * String \rightarrow String$ to store | ||
+ | # telephone number strings identified by a last and first name string: | ||
+ | # #+begin_src casm | ||
+ | # function phoneBook : String * String -> String | ||
+ | # #+end_src | ||
+ | # #+html: </callout> | ||
+ | |||
** Rules | ** Rules |