[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#55395: What does (1 2 3 . #2) mean?
From: |
Lars Ingebrigtsen |
Subject: |
bug#55395: What does (1 2 3 . #2) mean? |
Date: |
Fri, 13 May 2022 17:22:13 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) |
Mattias Engdegård <mattiase@acm.org> writes:
> It may have made more sense before the switch of cycle-detection algorithm
> from Floyd to Brent. This can be fixed by hand-coding the list iteration and
> explicitly remembering the index of the tortoise, but would that be correct?
> What's the spec?
I don't think I've ever considered #x to be meaningful outside of
print-circle, but I guess if we wanted to have some semantics here, I
think I would have expected the index of the tortoise? But...
> If #N means 'Nth object from the top along the path to the current object,
> starting at 0' then we should have
>
> (rho 2 3) => (1 2 3 4 5 . #2)
> (list (rho 2 3)) => ((1 2 3 4 5 . #3))
>
> ie, adding the print depth to the index in the list. Do you agree?
I've added Stefan to the CCs; I'm sure he has an opinion.
--
(domestic pets only, the antidote for overdose, milk.)
bloggy blog: http://lars.ingebrigtsen.no
- bug#55395: What does (1 2 3 . #2) mean?, Mattias Engdegård, 2022/05/13
- bug#55395: What does (1 2 3 . #2) mean?,
Lars Ingebrigtsen <=
- bug#55395: What does (1 2 3 . #2) mean?, Stefan Monnier, 2022/05/13
- bug#55395: What does (1 2 3 . #2) mean?, Lars Ingebrigtsen, 2022/05/13
- bug#55395: What does (1 2 3 . #2) mean?, Mattias Engdegård, 2022/05/13
- bug#55395: What does (1 2 3 . #2) mean?, Stefan Monnier, 2022/05/14
- bug#55395: What does (1 2 3 . #2) mean?, Mattias Engdegård, 2022/05/18
- bug#55395: What does (1 2 3 . #2) mean?, Stefan Monnier, 2022/05/18
- bug#55395: What does (1 2 3 . #2) mean?, Mattias Engdegård, 2022/05/23
bug#55395: What does (1 2 3 . #2) mean?, Andreas Schwab, 2022/05/13