Skip to content

Commit c140ce6

Browse files
committed
Cleaner handling of maps that are either dict or cl-custom-hash-table
1 parent 4d25d81 commit c140ce6

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

Diff for: compiler/compiler.lisp

+3-3
Original file line numberDiff line numberDiff line change
@@ -200,7 +200,7 @@ ARGS are the command-line args, available as `sys.argv'; can be a string (which
200200
(let ((*habitat* (or habitat (make-habitat))))
201201
(unless module-globals
202202
(setf module-globals (habitat-module-globals *habitat*)))
203-
(check-type module-globals (or hash-table package #+ecl cl-custom-hash-table::custom-hash-table))
203+
(assert (with-py-dict (hash-table-p module-globals)))
204204
(when args-p
205205
(setf (habitat-cmd-line-args *habitat*) args))
206206
(flet ((run ()
@@ -1545,7 +1545,7 @@ LOCALS shares share tail structure with input arg locals."
15451545
(multiple-value-bind (module module-new-p)
15461546
(ensure-module :src-pathname src-pathname :bin-pathname bin-pathname :name current-module-name)
15471547
(let ((%module-globals (module-ht module)))
1548-
(check-type %module-globals (or hash-table #+ecl cl-custom-hash-table::custom-hash-table))
1548+
(assert (with-py-dict (hash-table-p %module-globals)))
15491549
(flet ((init-module (&optional (module-globals %module-globals))
15501550
(init-module-namespace module-globals current-module-name))
15511551
(run-top-level-forms (&optional (module-globals %module-globals))
@@ -1581,7 +1581,7 @@ LOCALS shares share tail structure with input arg locals."
15811581
:run-tlv t
15821582
:globals %module-globals))
15831583
(continue-loading (&key (init t) (run-tlv t) (globals %module-globals))
1584-
(check-type globals (or hash-table #+ecl cl-custom-hash-table::custom-hash-table))
1584+
(assert (with-py-dict (hash-table-p globals)))
15851585
(setf %module-globals globals)
15861586
(when init
15871587
(init-module))

0 commit comments

Comments
 (0)