Closed cpockrandt closed 10 years ago
lambda
is its own type, an anonymous function. It's neither a list nor a string. See http://esolangs.org/wiki/Talk:Rail#Lambda.3F.
That's what I thougt as well. So you agree that there is a contradiction in the specification? Because the specification only allows lists and strings to be on the stack.
Yes, I would say that the specification is outdated then. Lambdas appear to be a pretty obscure (or new?) feature - they are only explained in detail on the discussion page of the Rail page in the Esolang wiki - so that's probably why the specification contains that contradiction.
On 9. Juli 2014 18:28:02 MESZ, cpockrandt notifications@github.com wrote:
That's what I thougt as well. So you agree that there is a contradiction in the specification? Because the specification only allows lists and strings to be on the stack.
Reply to this email directly or view it on GitHub: https://github.com/SWP-Ubau-SoSe2014-Haskell/SWPSoSe14/issues/164#issuecomment-48498713
I vote, we document this insight in the wiki: https://github.com/SWP-Ubau-SoSe2014-Haskell/SWPSoSe14/wiki/Specs-Rail, close this ticket and open new ones which handle lambdas. We need to be able to have lambdas as stack element, so (anonymous) functions should be allowed as a type. Typechecking should also be able to cope with lambdas. Do you figure, we'd be able to implement all this?
I have a question regarding the rail specs and the types of stack elements on the stack:
Esolang wiki says:
And we have a typecheck function
?: Returns 'string' or 'nil' or 'list' or 'lambda', depending on the type of the argument.
Since
n
is a list if and only ifn
is not a string, what the hell is lambda? Is it a list or a string? According to the definition it has to be exactly one of them. I'm so confused. Can someone please help me? :)