aboutsummaryrefslogtreecommitdiff
path: root/README.md
diff options
context:
space:
mode:
authordec05eba <dec05eba@protonmail.com>2019-09-09 01:28:26 +0200
committerdec05eba <dec05eba@protonmail.com>2020-07-25 14:36:46 +0200
commit7103d3a1df6c7fee6e8efbe3588204d1e869004e (patch)
tree844cb2a1d9a858b31423f4feb1d4792b16327aeb /README.md
parent16aaaa19a3ef4220726007d3e644ced0c9e06513 (diff)
Add code example to README
Diffstat (limited to 'README.md')
-rw-r--r--README.md9
1 files changed, 9 insertions, 0 deletions
diff --git a/README.md b/README.md
index 2668852..6137385 100644
--- a/README.md
+++ b/README.md
@@ -6,6 +6,15 @@ Amalgam is not meant to be a replacement for any other language but rather a new
with gpu without writing an external gpu program (glsl/hlsl).
Files have to be in utf-8 format and can optionally have utf-8 BOM.
+## Example
+Hello world example:
+```
+const io = @import("std/io.amal");
+
+const main = fn {
+ io.stdout.write("hello, world!\n");
+}
+```
## Important
Amalgam is not ready to be used yet.
# Fast compilation