|
592 | 592 | `(clojure.core/refer '~'clojure.core ~@filters)) |
593 | 593 |
|
594 | 594 | (defn sci-ns-resolve |
595 | | - ([sci-ctx ns sym] |
596 | | - (sci.impl.vars/with-bindings {sci.impl.utils/current-ns (sci-the-ns sci-ctx ns)} |
597 | | - (sci-resolve sci-ctx sym))) |
598 | | - ([sci-ctx ns env sym] |
599 | | - (sci.impl.vars/with-bindings {sci.impl.utils/current-ns (sci-the-ns sci-ctx ns)} |
600 | | - (sci-resolve sci-ctx env sym)))) |
| 595 | + ([ns sym] |
| 596 | + (let [ctx (store/get-ctx)] |
| 597 | + (sci.impl.vars/with-bindings {sci.impl.utils/current-ns (sci-the-ns ctx ns)} |
| 598 | + (sci-resolve ctx sym)))) |
| 599 | + ([ns env sym] |
| 600 | + (let [ctx (store/get-ctx)] |
| 601 | + (sci.impl.vars/with-bindings {sci.impl.utils/current-ns (sci-the-ns ctx ns)} |
| 602 | + (sci-resolve ctx env sym))))) |
601 | 603 |
|
602 | 604 | (defn sci-requiring-resolve |
603 | 605 | ([sci-ctx sym] |
|
727 | 729 |
|
728 | 730 | ;;;; Macroexpand |
729 | 731 |
|
730 | | -(defn macroexpand* [ctx expr] |
731 | | - (@sci.impl.utils/macroexpand* ctx expr)) |
| 732 | +(defn macroexpand* [expr] |
| 733 | + (@sci.impl.utils/macroexpand* (store/get-ctx) expr)) |
732 | 734 |
|
733 | | -(defn macroexpand-1* [ctx expr] |
734 | | - (@sci.impl.utils/macroexpand-1* ctx expr)) |
| 735 | +(defn macroexpand-1* [expr] |
| 736 | + (@sci.impl.utils/macroexpand-1* (store/get-ctx) expr)) |
735 | 737 |
|
736 | 738 | ;;;; |
737 | 739 |
|
|
1441 | 1443 | 'longs (copy-core-var longs) |
1442 | 1444 | 'list* (copy-core-var list*) |
1443 | 1445 | 'long-array (copy-core-var long-array) |
1444 | | - 'macroexpand (copy-var macroexpand* clojure-core-ns {:name 'macroexpand |
1445 | | - :ctx true}) |
1446 | | - 'macroexpand-1 (copy-var macroexpand-1* clojure-core-ns {:name 'macroexpand-1 |
1447 | | - :ctx true}) |
| 1446 | + 'macroexpand (copy-var macroexpand* clojure-core-ns {:name 'macroexpand}) |
| 1447 | + 'macroexpand-1 (copy-var macroexpand-1* clojure-core-ns {:name 'macroexpand-1}) |
1448 | 1448 | 'make-array (copy-core-var make-array) |
1449 | 1449 | 'make-hierarchy (copy-core-var make-hierarchy) |
1450 | 1450 | 'map (copy-core-var map) |
|
1478 | 1478 | 'nil? (copy-core-var nil?) |
1479 | 1479 | 'nat-int? (copy-core-var nat-int?) |
1480 | 1480 | 'ns (macrofy 'ns ns*) |
1481 | | - 'ns-resolve (copy-var sci-ns-resolve clojure-core-ns {:ctx true :name 'ns-resolve}) |
| 1481 | + 'ns-resolve (copy-var sci-ns-resolve clojure-core-ns {:name 'ns-resolve}) |
1482 | 1482 | 'number? (copy-core-var number?) |
1483 | 1483 | 'not-empty (copy-core-var not-empty) |
1484 | 1484 | 'not-any? (copy-core-var not-any?) |
|
0 commit comments