Commit c7e49a9
CLJS-1449: self-host: Error if :require-macros with :as
The k argument to cljs.js/load-macros should be either
a keyword or nil. The current implementation employs
an or construct that can set k to be the value false, and
when ultimately passed back into load-macros this
false value can inadvertently be used as a function.
This patch
a) revises the or construct to terminate wil a nil,
ensuring k will be be set to nil where previously it
would have been set to false
b) revises a spot where k is used to look up a value
in a map, reversing things so that the map is
instead used as the (non-nil) fn1 parent 4470993 commit c7e49a9
2 files changed
+23
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
353 | 353 | | |
354 | 354 | | |
355 | 355 | | |
356 | | - | |
| 356 | + | |
357 | 357 | | |
358 | | - | |
| 358 | + | |
| 359 | + | |
359 | 360 | | |
360 | 361 | | |
361 | 362 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
154 | 154 | | |
155 | 155 | | |
156 | 156 | | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
| 171 | + | |
| 172 | + | |
| 173 | + | |
| 174 | + | |
| 175 | + | |
| 176 | + | |
157 | 177 | | |
158 | 178 | | |
159 | 179 | | |
| |||
0 commit comments