Clojure

gen-class should allow exposes-methods to expose protected final methods

Details

  • Type: Enhancement Enhancement
  • Status: Closed Closed
  • Priority: Major Major
  • Resolution: Completed
  • Affects Version/s: Release 1.2
  • Fix Version/s: Release 1.5
  • Component/s: None
  • Labels:
    None
  • Patch:
    Code and Test
  • Approval:
    Ok

Description

Currently, there is no way in Clojure to call a protected final method of a superclass. While this may be an acceptable limitation for proxy, gen-class should provide that ability. Otherwise, one is now forced to create a dummy subclass in Java for the sole purpose of widening the visibility of such methods.

My patch makes it so that protected final methods may be exposed via the :exposes-methods mechanism. It is still impossible to override them.

Activity

Hide
Chouser added a comment -

Updated patch to apply cleanly to Clojure 1.4 SNAPSHOT. Included tests look good and pass.

Show
Chouser added a comment - Updated patch to apply cleanly to Clojure 1.4 SNAPSHOT. Included tests look good and pass.
Hide
Chouser added a comment -

Patch still applies, tests still pass.

Show
Chouser added a comment - Patch still applies, tests still pass.

People

Vote (2)
Watch (2)

Dates

  • Created:
    Updated:
    Resolved: