Clojure

for doesn't support :let binding as its first seq-expr

Details

  • 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:
    None
  • Environment:
    jvm clojure
  • Approval:
    Triaged

Description

user> (for [y [2 3 4] 
            :let [x 1]]
        [x y])
([1 2] [1 3] [1 4])
user> (for [:let [x 1]
            y [2 3 4]]
        [x y])
IllegalStateException Can't pop empty vector  clojure.lang.PersistentVector.pop (PersistentVector.java:380)

Cause:

Solution:

Patch:
Screened by:

Activity

Alex Miller made changes -
Field Original Value New Value
Labels bug
Alex Miller made changes -
Description (for [:let [x 1]
      y [2 3 4]]
  [x y])

;; fails with: IllegalStateException Can't pop empty vector clojure.lang.PersistentVector.pop (PersistentVector.java:380)
{code}
(for [:let [x 1]
      y [2 3 4]]
  [x y])
{code}

Fails with: IllegalStateException Can't pop empty vector clojure.lang.PersistentVector.pop (PersistentVector.java:380)
Alex Miller made changes -
Approval Triaged [ 10120 ]
Description {code}
(for [:let [x 1]
      y [2 3 4]]
  [x y])
{code}

Fails with: IllegalStateException Can't pop empty vector clojure.lang.PersistentVector.pop (PersistentVector.java:380)
{code}
user> (for [y [2 3 4]
            :let [x 1]]
        [x y])
([1 2] [1 3] [1 4])
user> (for [:let [x 1]
            y [2 3 4]]
        [x y])
IllegalStateException Can't pop empty vector clojure.lang.PersistentVector.pop (PersistentVector.java:380)
{code}

*Cause:*

*Solution:*

*Patch:*
*Screened by:*
Summary for doesn't support let as it's first seq-expr for doesn't support :let binding as it's first seq-expr
Alex Miller made changes -
Issue Type Defect [ 1 ] Enhancement [ 4 ]
Steve Miner made changes -
Summary for doesn't support :let binding as it's first seq-expr for doesn't support :let binding as its first seq-expr

People

Vote (1)
Watch (3)

Dates

  • Created:
    Updated: