Reflection warning in clojure.reflect

Description

We introduced some unintentional reflection in the new Java reflect datafy changes. If you set warn-on-reflection to true it shows up as:

[java] Reflection warning, clojure/reflect/java.clj:182:35 - reference to field getModifiers on java.lang.Object can't be resolved.

Basically the new typeref->class lost the Class marker introducing reflection.

Proposed: Type hint the return of typeref->class.

Patch: clj-2436.patch - add set! of warn-on-reflection, type hint return of typeref->class, fix indent on one line.

Environment

None

Attachments

1
  • 20 Nov 2018, 02:46 PM

Activity

Show:
Completed

Details

Assignee

Reporter

Approval

Ok

Patch

Code

Priority

Affects versions

Fix versions

Created November 20, 2018 at 2:38 PM
Updated December 6, 2018 at 4:44 AM
Resolved December 6, 2018 at 4:44 AM