Error Message when calling deref on a non-IDeref is unhelpful


  • Type: Enhancement Enhancement
  • Status: Open Open
  • Priority: Minor Minor
  • Resolution: Unresolved
  • Affects Version/s: Release 1.5
  • Fix Version/s: None
  • Component/s: None
  • Labels:
  • Environment:
    Found this on ubuntu, lein 2, Clojure 1.5 snapshot, but it's obvious from inspection
  • Patch:


If you just type "@1" is the repl, on previous versions you'll get an error that Long cannot be cast to IDeref. In 1.5, the error message is that it cannot be cast to java.util.concurrent.Future. This is because it assumes that anything that isn't an IDeref is automatically a Future. The deref method should generate a custom error stating that the type you've passed in is neither an IDeref nor a Future.


Stuart Halloway made changes -
Field Original Value New Value
Issue Type Defect [ 1 ] Enhancement [ 4 ]
Gary Fredericks made changes -
Attachment CLJ-1162-p1.patch [ 12016 ]
Andy Fingerhut made changes -
Patch Code [ 10001 ]
Alex Miller made changes -
Labels errormsgs


Vote (2)
Watch (2)


  • Created: