diff options
author | dos-reis <gdr@axiomatics.org> | 2011-12-10 18:54:17 +0000 |
---|---|---|
committer | dos-reis <gdr@axiomatics.org> | 2011-12-10 18:54:17 +0000 |
commit | 49fc7b2f58f56ea7c9aa8169be3dfcc22b818be2 (patch) | |
tree | b9475624cbe821fff9753a08ef614396ffe8f2e4 /src/boot/ast.boot | |
parent | 1bee5e2ddcac5cd3a168f5f70a754fd8bee34021 (diff) | |
download | open-axiom-49fc7b2f58f56ea7c9aa8169be3dfcc22b818be2.tar.gz |
* boot/parser.boot (bpArgtypeList): Accept mapping types.
* boot/ast.boot (bfType): New.
* boot/translator.boot (genDeclaration): Use it.
* boot/utility.boot (every?): New. Export.
(any?): Likewise.
(takeWhile): Lilkewise.
Diffstat (limited to 'src/boot/ast.boot')
-rw-r--r-- | src/boot/ast.boot | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/boot/ast.boot b/src/boot/ast.boot index be52533d..4a476189 100644 --- a/src/boot/ast.boot +++ b/src/boot/ast.boot @@ -1344,6 +1344,18 @@ bfThrow e == ["THROW",KEYWORD::OPEN_-AXIOM_-CATCH_-POINT, ["CONS",KEYWORD::OPEN_-AXIOM_-CATCH_-POINT,["CONS",t,x]]] +--% + +bfType x == + x is ['%Mapping,t,s] => + if bfTupleP s then + s := s.args + if ident? s then + s := [s] + ['FUNCTION,[bfType y for y in s],bfType t] + x is [.,:.] => [x.op,:[bfType y for y in x.args]] + x + --% Type alias definition backquote: (%Form,%List %Symbol) -> %Form |