summaryrefslogtreecommitdiff
path: root/Src/hashtable.c
diff options
context:
space:
mode:
authorPeter Stephenson <pws@zsh.org>2015-06-18 14:54:41 +0100
committerPeter Stephenson <pws@zsh.org>2015-06-24 10:21:12 +0100
commit39b28980f38e83e15cdeb19a489b5659af97fe93 (patch)
treee68f09fc59fc7008ff732704cbabed7e3df5f188 /Src/hashtable.c
parenta68d22eb00ea5c85422d70d1be7efa42acfda739 (diff)
downloadzsh-39b28980f38e83e15cdeb19a489b5659af97fe93.tar.gz
zsh-39b28980f38e83e15cdeb19a489b5659af97fe93.zip
various posts: Implement assignment parsing for typeset.
Typeset assignments now work like raw assignments except for no "+=" and no GLOB_ASSIGN. Documented in typeset builtin doc and mentioned in release notes. Tests to ensure basic sanity. Enabled by default, can be turned off by "disable -r" with typeset family of commands.
Diffstat (limited to 'Src/hashtable.c')
-rw-r--r--Src/hashtable.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/Src/hashtable.c b/Src/hashtable.c
index 2b5524999..90739a882 100644
--- a/Src/hashtable.c
+++ b/Src/hashtable.c
@@ -1050,22 +1050,29 @@ static struct reswd reswds[] = {
{{NULL, "}", 0}, OUTBRACE},
{{NULL, "case", 0}, CASE},
{{NULL, "coproc", 0}, COPROC},
+ {{NULL, "declare", 0}, TYPESET},
{{NULL, "do", 0}, DOLOOP},
{{NULL, "done", 0}, DONE},
{{NULL, "elif", 0}, ELIF},
{{NULL, "else", 0}, ELSE},
{{NULL, "end", 0}, ZEND},
{{NULL, "esac", 0}, ESAC},
+ {{NULL, "export", 0}, TYPESET},
{{NULL, "fi", 0}, FI},
+ {{NULL, "float", 0}, TYPESET},
{{NULL, "for", 0}, FOR},
{{NULL, "foreach", 0}, FOREACH},
{{NULL, "function", 0}, FUNC},
{{NULL, "if", 0}, IF},
+ {{NULL, "integer", 0}, TYPESET},
+ {{NULL, "local", 0}, TYPESET},
{{NULL, "nocorrect", 0}, NOCORRECT},
+ {{NULL, "readonly", 0}, TYPESET},
{{NULL, "repeat", 0}, REPEAT},
{{NULL, "select", 0}, SELECT},
{{NULL, "then", 0}, THEN},
{{NULL, "time", 0}, TIME},
+ {{NULL, "typeset", 0}, TYPESET},
{{NULL, "until", 0}, UNTIL},
{{NULL, "while", 0}, WHILE},
{{NULL, NULL, 0}, 0}