Commit 7171db2
committed
CLJS-3239: Infinite analysis with dotted symbols
The analysis change for dotted symbols revealed a bug with import parsing.
`(:import goog)` would result in `:imports {goog goog}` in the ns analysis
map. Then when resolving a symbol like `goog.debug.Console`, the analyzer would
go into an infinite loop. This loop was in the `:import` branch of resolve-var.
This is because the expectation is that the value side of `:imports` map
is *different*. But in this case, `{goog goog}`, it is not different, so the
analyzer would get stuck.
Notably, `(:import [goog])` doesn't have this problem.
Make `(:import goog)` match `(:import [goog])`1 parent 16e2ce4 commit 7171db2
File tree
2 files changed
+10
-8
lines changed- src
- main/clojure/cljs
- test/clojure/cljs
2 files changed
+10
-8
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2915 | 2915 | | |
2916 | 2916 | | |
2917 | 2917 | | |
2918 | | - | |
| 2918 | + | |
| 2919 | + | |
2919 | 2920 | | |
2920 | 2921 | | |
2921 | 2922 | | |
2922 | | - | |
| 2923 | + | |
| 2924 | + | |
| 2925 | + | |
| 2926 | + | |
| 2927 | + | |
2923 | 2928 | | |
2924 | 2929 | | |
2925 | 2930 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1485 | 1485 | | |
1486 | 1486 | | |
1487 | 1487 | | |
1488 | | - | |
1489 | | - | |
| 1488 | + | |
1490 | 1489 | | |
1491 | 1490 | | |
1492 | 1491 | | |
1493 | 1492 | | |
1494 | | - | |
1495 | | - | |
1496 | | - | |
1497 | | - | |
| 1493 | + | |
| 1494 | + | |
0 commit comments