Details
-
Type:
Defect
-
Status:
Open
-
Priority:
Major
-
Resolution: Unresolved
-
Affects Version/s: None
-
Fix Version/s: None
-
Component/s: None
-
Labels:None
-
Environment:Clojure 1.3
Description
Using the latest core.match:
user=> (let [x []] (match [x] [[h & t]] [h t] :else :nomatch))
IndexOutOfBoundsException clojure.lang.RT.subvec (RT.java:1451)
Not sure if this is the best fix, but I resolved this specific case by slightly changing subvec-inline (see attached diff).
Thanks for the report. The patch is not going to work - we should be checking that the vector has at least one item.