1
0
mirror of https://github.com/KarolS/millfork.git synced 2026-04-21 09:16:34 +00:00

Short syntax for small functions

This commit is contained in:
Karol Stasiak
2019-04-15 19:56:14 +02:00
parent 029e84b0f0
commit d0f64f2cee
5 changed files with 16 additions and 5 deletions
+4
View File
@@ -6,6 +6,8 @@ Syntax:
`[segment (<segment>)] [<modifiers>] <return_type> <name> ( <params> ) [align ( <alignment> )] [@ <address>] { <body> }`
`[segment (<segment>)] [<modifiers>] <return_type> <name> ( <params> ) [align ( <alignment> )] [@ <address>] = <expression>`
`[segment (<segment>)] asm <return_type> <name> ( <params> ) @ <address> extern`
* `<segment>`: segment name; if absent, then defaults to `default_code_segment` as defined for the platform (usually `default`)
@@ -53,3 +55,5 @@ Such functions should be marked as written in assembly and should have their par
* `<body>` is a newline-separated list of either Millfork or assembly statements
* `<expression>` is an expression. It is equivalent to a function body of form `{ return <expression> }`.