Problem
I tried to use {{clojure.stracktrace/print-stack-trace}} with GraalVM but that doesn't work since reflection is needed to find the method {{getMessage}}.
Proposed solution
This can be resolved by adding type hints.
An overview of warnings emitted by
`
(set! warn-on-reflection true)`
:
Reflection warning, /tmp/stacktrace.clj:24:18 - reference to field getCause can't be resolved.
Reflection warning, /tmp/stacktrace.clj:32:15 - reference to field getClassName can't be resolved.
Reflection warning, /tmp/stacktrace.clj:33:9 - reference to field getMethodName can't be resolved.
Reflection warning, /tmp/stacktrace.clj:38:26 - reference to field getFileName can't be resolved.
Reflection warning, /tmp/stacktrace.clj:38:47 - reference to field getLineNumber can't be resolved.
Reflection warning, /tmp/stacktrace.clj:45:42 - reference to field getMessage can't be resolved.
Reflection warning, /tmp/stacktrace.clj:24:18 - reference to field getCause can't be resolved.
Patch CLJ-2502-2.patch removes unwanted whitespace changes and moves the type hint of {{root-cause}} higher up.
Screened by: Alex Miller