Skip to content

Commit e324713

Browse files
gerritjvvstuarthalloway
authored andcommitted
CLJ-2048 add StackTraceElement to throw-if into-array to avoid classcastexception on [Object array when stack trace is nil
Signed-off-by: Stuart Halloway <stu@cognitect.com>
1 parent 9048707 commit e324713

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/clj/clojure/core.clj

+2-2
Original file line numberDiff line numberDiff line change
@@ -5763,7 +5763,7 @@
57635763
exception (Exception. message)
57645764
raw-trace (.getStackTrace exception)
57655765
boring? #(not= (.getMethodName ^StackTraceElement %) "doInvoke")
5766-
trace (into-array (drop 2 (drop-while boring? raw-trace)))]
5766+
trace (into-array StackTraceElement (drop 2 (drop-while boring? raw-trace)))]
57675767
(.setStackTrace exception trace)
57685768
(throw (clojure.lang.Compiler$CompilerException.
57695769
*file*
@@ -7718,4 +7718,4 @@
77187718
(defn uri?
77197719
"Return true if x is a java.net.URI"
77207720
{:added "1.9"}
7721-
[x] (instance? java.net.URI x))
7721+
[x] (instance? java.net.URI x))

0 commit comments

Comments
 (0)