Skip to content

Commit 5b13daf

Browse files
committed
Update to Java commit cf578d0 (2023.03.13): guard on no ns decl in JAR
1 parent e497248 commit 5b13daf

File tree

1 file changed

+5
-4
lines changed
  • src/main/clojure/clojure/tools/namespace

1 file changed

+5
-4
lines changed

src/main/clojure/clojure/tools/namespace/find.clj

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -161,10 +161,11 @@
161161
;;; (io/reader
162162
;;; (.getInputStream jarfile (.getEntry jarfile entry-name))))]
163163
;;; (ignore-reader-exception
164-
;;; (let [[_ nom & more] (parse/read-ns-decl rdr read-opts)]
165-
;;; (list* 'ns (with-meta nom
166-
;;; {:jar (.getName ^JarFile jarfile) :file entry-name})
167-
;;; more)))))))
164+
;;; (let [[_ nom & more :as decl] (parse/read-ns-decl rdr read-opts)]
165+
;;; (when (and decl nom (symbol? nom))
166+
;;; (list* 'ns (with-meta nom
167+
;;; {:jar (.getName ^JarFile jarfile) :file entry-name})
168+
;;; more))))))))
168169
(defn find-ns-decls-in-jarfile
169170
"Searches the JAR file for source files containing (ns ...)
170171
declarations; returns the unevaluated ns declarations.

0 commit comments

Comments
 (0)