aboutsummaryrefslogtreecommitdiff
path: root/test/lang.tm
diff options
context:
space:
mode:
Diffstat (limited to 'test/lang.tm')
-rw-r--r--test/lang.tm10
1 files changed, 5 insertions, 5 deletions
diff --git a/test/lang.tm b/test/lang.tm
index ad09b605..3dea6ded 100644
--- a/test/lang.tm
+++ b/test/lang.tm
@@ -1,6 +1,6 @@
-lang HTML
+lang HTML:
HEADER := $HTML{}"<!DOCTYPE HTML>"
- func escape(t:Text)->HTML
+ func escape(t:Text)->HTML:
t = t:replace("&", "&amp;")
t = t:replace("<", "&lt;")
t = t:replace(">", "&gt;")
@@ -8,13 +8,13 @@ lang HTML
t = t:replace("'", "&#39;")
return HTML.from_unsafe_text(t)
- func escape_int(i:Int)->HTML
+ func escape_int(i:Int)->HTML:
return HTML.from_unsafe_text("{i}")
- func paragraph(content:HTML)->HTML
+ func paragraph(content:HTML)->HTML:
return $HTML{}"<p>{content}</p>"
-func main()
+func main():
>> HTML.HEADER
= $HTML"<!DOCTYPE HTML>"