diff options
author | Saem Ghani <saemghani+github@gmail.com> | 2021-02-15 00:51:05 -0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-02-15 09:51:05 +0100 |
commit | 260a5dacb7a3854d6d6aa18d9996b88bfcd13cc6 (patch) | |
tree | 175b30daf8594641e5f47e0576914e73fd386594 /tests/js | |
parent | b68ecc82cb404dbbd291320139955794e88c24ff (diff) | |
download | Nim-260a5dacb7a3854d6d6aa18d9996b88bfcd13cc6.tar.gz |
fixed dot operator recursive loop & macro suggest (#16922)
* basic stability improvements; refs nimsuggest * fixed dot operator recursive loop & macro suggest * hacky fix for run away dot operator sem check Committing this mostly to make the issue more clear. Perhaps get better feedback. * semExprWithType seems like a better place to check * fixed error messages const case expressions * Clean-up test * stopped the dot operator madness No longer get infinite recursion when seming broken code with a dot operator macro like in jsffi. Co-authored-by: Araq <rumpf_a@web.de>
Diffstat (limited to 'tests/js')
-rw-r--r-- | tests/js/t11166.nim | 18 |
1 files changed, 17 insertions, 1 deletions
diff --git a/tests/js/t11166.nim b/tests/js/t11166.nim index 8dd77925c..e98ccda10 100644 --- a/tests/js/t11166.nim +++ b/tests/js/t11166.nim @@ -1,4 +1,20 @@ +discard """ + output: ''' +test1 +test2 +''' +""" + import jsffi +type + C = object + props: int + +var c: C + when compiles(c.props): - echo "test" + echo "test1" + +when not compiles(d.props): + echo "test2" |