diff options
author | alaviss <alaviss@users.noreply.github.com> | 2019-11-04 17:29:26 +0000 |
---|---|---|
committer | Andreas Rumpf <rumpf_a@web.de> | 2019-11-04 18:29:26 +0100 |
commit | 558ecd1ca64fecc2ef43bb327dcd055e199beec5 (patch) | |
tree | 0f61e09b71e165010887a27de8abd7ebaaa795ba /nimsuggest/tests/tcon_variable.nim | |
parent | ae32d637f7f6a590d8cd1b825df004359999bb90 (diff) | |
download | Nim-558ecd1ca64fecc2ef43bb327dcd055e199beec5.tar.gz |
compiler/suggest: add variable support to `con` (#12569)
This allows for the type of a variable to be retrieved.
Diffstat (limited to 'nimsuggest/tests/tcon_variable.nim')
-rw-r--r-- | nimsuggest/tests/tcon_variable.nim | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/nimsuggest/tests/tcon_variable.nim b/nimsuggest/tests/tcon_variable.nim new file mode 100644 index 000000000..cfe93604f --- /dev/null +++ b/nimsuggest/tests/tcon_variable.nim @@ -0,0 +1,12 @@ +let foo = "string" +var bar = "string" +bar#[!]#.add foo +bar.add foo#[!]# + +discard """ +$nimsuggest --tester $file +>con $1 +con;;skVar;;tcon_variable.bar;;string;;$file;;2;;4;;"";;100 +>con $2 +con;;skLet;;tcon_variable.foo;;string;;$file;;1;;4;;"";;100 +""" |