Statements dreamed up by the utterly deranged :comfyderp:

Imagine trying to top up JavaScript's ridiculousness and winning!

Or this:
> (eq 'a 'b) is false.
> (eq 'a 'a) is true.
> (eq 3 3) might be true or false, depending on the implementation.

In what universe 3 and 3 might not be equal by any metric imaginable? Common Lisp is truly a cursed language.

Every time I try to love Common Lisp, it slaps me on the face with a huge club and leaves me bleeding. Truly cursed language.

@pureevil

I'm lucky enough to only have used racket and scheme (small amount of guile too)

CLisp is scary
@pureevil


To be fair, those equality checks all mostly seem useful, if you don't wanna do specific checks,

But idk, I mostly just use eq and if it doesn't work, I do some mutations

@lunarised what if I just wanna compare to values? Surely, I could just use `equal` everywhere, except it doesn't always work on symbols.

From cs.cmu.edu/Groups/AI/html/cltl:
>Symbols are compared as for eq. This method of comparing symbols can violate the rule of thumb for equal and printed representations, but only in the infrequently occurring case of two distinct symbols with the same print name.

What the literal fuck is this shit? :facepalm_cirno:

@lunarised going further, from the same page:
>Two arrays are equal only if they are eq, with one exception: strings and bit-vectors are compared element-by-element.

I have no idea how anyone can take this language seriously. It's even more of a joke than JavaScript.

@pureevil

JS is alright tbh now with===

I imagine since CLisp is (60?) Years old, there's probably reasons for all this
Follow

@lunarised yeah. And it's probably an incredible amount of really really stupid reasons, none of which I could give a single damn about.

Look, if I can't just compare two values for equality in your language without having to bother about what those values are, then it's probably not a good language.

@pureevil all I want is 2 equality operators

Referencial equality: If thing1 has the same memory address as thing2, and value equality

All else should be implemented by the user

@lunarised just one is enough. If you want to compare references, then do exactly that and compare references.

(eq (ref a) (ref b))

for example. There's literally no need for more than one equality operator ever.

Sign in to participate in the conversation
Functional Café

The social network of the future: No ads, no corporate surveillance, ethical design, and decentralization! Own your data with Mastodon!