git.iko.soy/rowtype-yoga/purescript-native
on golang help sign in
Update README.md
commit5bc25c984a44272ce1e4c5d352db702f361219b6 authorPhil Freeman <paf31@cantab.net> dateSun 10 Nov 2013, 21:47 (13 years ago) parent249ff93
1 file changed+31
README.md+31
README.md+31
@@ -638,6 +638,37 @@ infixl 5 <>
638638infixr 7 %%
639639```
640640
641+## Modules
642+
643+Simple modules are supported by the `module` keyword.
644+
645+Introduce a module as follows, with a list of indented declarations:
646+
647+```haskell
648+module A where
649+
650+ foo = \x -> x
651+```
652+
653+Modules may be nested:
654+
655+```haskell
656+module A where
657+
658+ foo = \x -> x
659+
660+ module B where
661+
662+ bar = \y -> y
663+```
664+
665+Names may be qualified by using a colon:
666+
667+```
668+foo = A:foo
669+bar = A:B:bar
670+```
671+
641672## Foreign Function Interface
642673
643674The `foreign import` keyword declares a value which is defined in Javascript, and its type: