An unofficial, read-only Hacker News reader. Join the beta →

I checked Clojure's core with Lean and found unreported bugs (opens external site)

238 points by encyclopedism 2 days ago | s.conao3.com | 84 comments on HN

View full thread · View on Hacker News

Comment thread (1)

  1. To clarify, by "type mismatch", I meant checking if an int value occurs in a byte array (and, hence, in the wrapping sequence). Of course, appropriate type coercion would prevent such a mismatch.

    The disagreement between `.indexOf` and `.contains` is interesting. Nice catch!!

    Digging into the code, `.indexOf` invokes `ArraySeq_byte.indexOf` while `.contains` invokes `ASeq.contains`. Interestingly, `ASeq.contains` and `ASeq.indexOf` have similar behavior while `ArraySeq_byte.indexOf` and `ASeq.contains` different behavior.