Why Was "<>" Removed?

Discuss the future of the AutoHotkey language
SOTE
Posts: 1426
Joined: 15 Jun 2015, 06:21

Re: Why Was "<>" Removed?

20 Mar 2020, 05:43

Helgef wrote:
20 Mar 2020, 02:19
if "<>" can be so casually thrown away, why not throw away the rest of the "divergent" operators too. Like say ":=" and replace it with "="
I don't know why you think lexikos is casually throwing things away. As gregster said, the choice to between <>/!= (or both) isn't comparable to the choice between := and =.

Anyways, the way I see it, removing <> from ahk v2 alpha wasn't about removing it from the language, is was about not adding it to AHK v2. If you cannot give a good answer as to why something should be in ahk v2, then it shouldn't be there. And no one have given a good answer as to why we need both != and <>, probably because there isn't any.

Cheers.
If you are going to use Gregster, why not add the other part. He was fine with keeping "<>".
But spending time on != vs <> seems irrelevant. That said, I wouldn't mind keeping it...
I believe "<>" was originally in AHK v2, and was only removed in more recent versions. And if it's something that is in the language and in people's scripts, then we are talking removal from the language versus not adding to AutoHotkey.

Many people also get confused by ":=", because they aren't familiar with it. Along those lines, AutoHotkey's "==" is as equally confusing, as it doesn't mean the same as in other languages. An argument can be made for rearranging "=" and "==", so that they mean the same as with C and other languages. "=" for assignment and "==" for equal to.

For that matter, nobody has ever given a good answer as to why AutoHotkey uses ":=". If there isn't any, why not change it in AHK v2 too. Or do we not do such, because a tradition of usage has already been established? That's partially the point I'm making.
gregster
Posts: 9111
Joined: 30 Sep 2013, 06:48

Re: Why Was "<>" Removed?

20 Mar 2020, 07:54

If you are all going to quote me, here is another, fresh statement:
I don't see much added value in recent statements. If someone has a fresh argument and really wants to get it out - now is the time, but please refrain from endlessly arguing over the same opinions. Thank you!
_3D_
Posts: 277
Joined: 29 Jan 2014, 14:40

Re: Why Was "<>" Removed?

23 Mar 2020, 08:42

  • About := and =
    There was "referendum" what syntax to keep. I vote := because it is visual different from =.
    In other case {<ident>: <value>} : => <ident> accepts <value>.
  • About != and <>
    <> it is outdated syntax that not corresponding to NOT ! EQUAL = which is visual similar to .
    <> probably mean LESS < or GREAT >.
    In other hand != corresponding to !value that mean NOT value and in Pascal no so syntax <>value.
    So ! mean NOT.

Code: Select all

a := 1	;a accepts value equal to 1
{a: 1}	;a accepts 1
a != 2	;is a not equal to 2
if !a	;if not value of a
AHKv2.0 alpha forever.
SOTE
Posts: 1426
Joined: 15 Jun 2015, 06:21

Re: Why Was "<>" Removed?

23 Mar 2020, 11:37

_3D_ wrote:
23 Mar 2020, 08:42
<> it is outdated syntax that not corresponding to NOT ! EQUAL = which is visual similar to .
"<>" is not outdated syntax. This statement by itself is arguably misinformation. The syntax is valid and presently used in multiple programming languages (some of which I have listed in previous posts).

The thinking that it's "outdated", is debatably disguising one's preference. However, a person's preference can be detrimental to another person. As there are those that use or prefer to use the "<>" in AutoHotkey (and have it in their scripts), and this can correspond to their preference for other programming languages that use it as well.

The opinion that I'm putting forth is that AutoHotkey should try to be "agnostic" or as "user friendly" as possible. Which AHK v1 has debatably achieved, to the amazement of many. AHK v1 as a programming language, makes it very easy to jump to numerous other programming languages like JavaScript, Swift, Go, Object Pascal, etc... Because it has syntax, operators, and features common to those other languages. AHK v2 makes itself less "user friendly" or more in jeopardy of losing its agnostic nature, when it takes a more definitive path and hardened stance in terms of style, syntax, and operators.
<> probably mean LESS < or GREAT >.
This is opinion about looks versus facts about definition. I have already shown a visual progression which disputes this argument. "<>" definitively means not equal in programming, and is defined as such in multiple other programming languages. Stating otherwise, is going against official documentation and definitions.
_3D_
Posts: 277
Joined: 29 Jan 2014, 14:40

Re: Why Was "<>" Removed?

23 Mar 2020, 12:51

SOTE wrote:
23 Mar 2020, 11:37
Losing time to talking about "is that <> cool or not" is pure losing time. It is 5 lines code that will convert all your scripts from <> to !=.
AHKv2.0 alpha forever.
SOTE
Posts: 1426
Joined: 15 Jun 2015, 06:21

Re: Why Was "<>" Removed?

23 Mar 2020, 22:25

If it were really so inconsequential, then there would be no need to even remove it. There should have been a hundred other things to touch and upgrade from AHK v1, where this would be the last on the list or never bothered with.

Return to “AutoHotkey Development”

Who is online

Users browsing this forum: No registered users and 17 guests