Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Popping 'some' doesn't change original list #8

Open
masak opened this issue Aug 22, 2020 · 0 comments
Open

Popping 'some' doesn't change original list #8

masak opened this issue Aug 22, 2020 · 0 comments

Comments

@masak
Copy link

masak commented Aug 22, 2020

> (set L '(2 4 5 6 8))
(2 4 5 6 8)

> (some odd L)
(5 6 8)

> (pop (some odd L))
5

> L
(2 4 5 6 8)

Expected the 5 gone here.

This works:

> (pop (cddr L))
5

> L
(2 4 6 8)

So probably the problem has to do with some not returning a suffix of L that pop can modify.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant