Clojure

reify ignores :pre and :post

Details

  • Type: Enhancement Enhancement
  • Status: Closed Closed
  • Priority: Minor Minor
  • Resolution: Completed
  • Affects Version/s: Release 1.4
  • Fix Version/s: None
  • Component/s: None
  • Labels:
    None

Description

reify ignores :pre and :post assertions

user=> ((reify clojure.lang.IFn (invoke [this] {:pre [false]} (println "hello"))))
hello
nil
user=> ((fn [this] {:pre [false]} (println "hello")) 0)
AssertionError Assert failed: false user/eval39/fn--40 (NO_SOURCE_FILE:13)

Expected exception to be thrown

Activity

Hide
Timothy Baldridge added a comment -

Vetted.

Show
Timothy Baldridge added a comment - Vetted.
Hide
Stuart Halloway added a comment -

reify is not documented to support these, so this should be classified as an enhancement

Show
Stuart Halloway added a comment - reify is not documented to support these, so this should be classified as an enhancement

People

Vote (0)
Watch (1)

Dates

  • Created:
    Updated:
    Resolved: