digitalmars.D - not operator operator..
- S. Chancellor (13/13) Apr 03 2006 I really really hate the !in, !is syntax. I think a lot of other
- Wang Zhen (5/25) Apr 03 2006 I don't hate !is and !in, but if they were to change, I would suggest a
- kris (3/20) Apr 03 2006 D !is BASIC
- Charles (3/29) Apr 04 2006 Hehe.
- Regan Heath (9/12) Apr 03 2006 I like !in and !is.
- S. Chancellor (2/19) Apr 04 2006 !is is ugly and hard to read, code is supposed to be beautiful.
- Regan Heath (6/22) Apr 04 2006 I disagree on both points.
- Derek Parnell (13/20) Apr 04 2006 While that may be true, code is also meant to be easy to read by humans....
- John C (2/5) Apr 04 2006 Clearly you've never read Yeats, Auden or Eliot. Frankly they make Engli...
- Regan Heath (11/17) Apr 04 2006 In visual appearance or actual meaning? I think code and writing can be ...
- Jarrett Billingsley (8/12) Apr 03 2006 Ew.
- Derek Parnell (18/19) Apr 03 2006 A language that I use daily (Progress 4GL) not only has the standard
- =?ISO-8859-1?Q?Anders_F_Bj=F6rklund?= (4/18) Apr 04 2006 The same is also used in Perl and in PPC assembler.
- =?ISO-8859-1?Q?Anders_F_Bj=F6rklund?= (6/12) Apr 04 2006 This could work for "is" and "not is" too,
- Bruno Medeiros (5/24) Apr 04 2006 Eewww..
- S. Chancellor (6/24) Apr 04 2006 I didn't say I wanted to program in AppleScript. :P I hate mixing
- =?UTF-8?B?QW5kZXJzIEYgQmrDtnJrbHVuZA==?= (14/18) Apr 04 2006 Sure there is. ≡ in Unicode (\u2261), or === in plain ASCII.
- Georg Wrede (15/25) Apr 04 2006 If D really _demands_ source code to be in UTF, then there is no excuse
- Regan Heath (5/17) Apr 04 2006 Except that they're not easily acessable on a common/standard keyboard, ...
- Derek Parnell (9/27) Apr 04 2006 What? You mean you're *not* using the standard 473-key keyboard? How
- Georg Wrede (25/47) Apr 04 2006 If somebody is able to produce "≡", then let him define it. All we nee...
- Derek Parnell (11/25) Apr 04 2006 I'm sorry Georg, I wasn't disapproving of your idea, I was just making a
- =?UTF-8?B?QW5kZXJzIEYgQmrDtnJrbHVuZA==?= (9/38) Apr 05 2006 An old feature request was that D should allow Unicode operators,
- Chris Miller (5/9) Apr 05 2006 Not everyone supports unicode very well. What happens when I try looking...
- Deewiant (2/16) Apr 05 2006 Isn't that point defeated by the fact that we have Unicode identifiers?
- Lars Ivar Igesund (6/24) Apr 05 2006 Not really, as you currently know that identifiers can be Unicode, but n...
- Deewiant (11/34) Apr 05 2006 The problem is that, even now, in the worst case you can get something t...
- Jarrett Billingsley (5/11) Apr 05 2006 Don't forget:
- =?UTF-8?B?QW5kZXJzIEYgQmrDtnJrbHVuZA==?= (7/14) Apr 05 2006 I thought D only supported Unicode platforms ?
- Lars Ivar Igesund (3/18) Apr 05 2006 I have an utf-enabled email-client but that character is not present in ...
- Norbert Nemec (12/12) Apr 03 2006 Sorry, I don't agree. != has been in C for ages and any C programmer
- =?ISO-8859-1?Q?Anders_F_Bj=F6rklund?= (8/14) Apr 04 2006 Ehrm, wasn't '===' changed to 'is' exactly because it was more readable?
- Don Clugston (3/22) Apr 04 2006 I thought it was because === was almost indistinguishable from == with
- =?ISO-8859-1?Q?Anders_F_Bj=F6rklund?= (4/8) Apr 04 2006 Yes, I guess that would qualify as "unreadable" when using such a font.
- S. Chancellor (2/14) Apr 04 2006 !is is pretty hard to read to me. I hate having the ! next to the i.
- Jarrett Billingsley (4/5) Apr 04 2006 It's easy to read for me. And for most people, apparently, considering ...
- S. Chancellor (13/29) Apr 04 2006 issue !is that !is is ! easy to understand, the issue is that it's a
- Regan Heath (6/8) Apr 04 2006 What font are you using, the above is perfectly clear to me, ! and i loo...
- Derek Parnell (10/12) Apr 04 2006 Select the 'Tools' menu.
- Regan Heath (3/13) Apr 04 2006 Ta. It's "Courier New" then.
- =?ISO-8859-1?Q?Anders_F_Bj=F6rklund?= (7/14) Apr 04 2006 But this just looks just as horrible ?
- Kyle Furlong (2/23) Apr 04 2006 And that would be a resounding NO.
- S. Chancellor (3/23) Apr 04 2006 I liked the other syntax better. But this isn't perl, there shouldn't
- Mike Parker (3/6) Apr 04 2006 I sure hope it doesn't.
- Lars Ivar Igesund (2/11) Apr 04 2006 I agree with Mike here. On both accounts.
- Georg Wrede (2/19) Apr 04 2006 So do I.
I really really hate the !in, !is syntax. I think a lot of other people do too. I propose that the word not, become an operator on operators. For example: Foo not is null Foo not in Bar This not keyword will only function when it is part of these expressions: EqualExpression RelExpression InExpression As a consequence the following would be valid: Foo not == Bar Foo not <= Bar -S.
Apr 03 2006
S. Chancellor wrote:I really really hate the !in, !is syntax. I think a lot of other people do too. I propose that the word not, become an operator on operators. For example: Foo not is null Foo not in Bar This not keyword will only function when it is part of these expressions: EqualExpression RelExpression InExpression As a consequence the following would be valid: Foo not == Bar Foo not <= Bar -S.I don't hate !is and !in, but if they were to change, I would suggest a more succinct syntax: !is => not !in => out
Apr 03 2006
S. Chancellor wrote:I really really hate the !in, !is syntax. I think a lot of other people do too. I propose that the word not, become an operator on operators. For example: Foo not is null Foo not in Bar This not keyword will only function when it is part of these expressions: EqualExpression RelExpression InExpression As a consequence the following would be valid: Foo not == Bar Foo not <= BarD !is BASIC ;-)
Apr 03 2006
D !is BASICHehe. I personally prefer the !is syntax . kris wrote:S. Chancellor wrote:I really really hate the !in, !is syntax. I think a lot of other people do too. I propose that the word not, become an operator on operators. For example: Foo not is null Foo not in Bar This not keyword will only function when it is part of these expressions: EqualExpression RelExpression InExpression As a consequence the following would be valid: Foo not == Bar Foo not <= BarD !is BASIC ;-)
Apr 04 2006
On Mon, 3 Apr 2006 20:34:24 -0700, S. Chancellor <dnewsgr mephit.kicks-ass.org> wrote:I really really hate the !in, !is syntax. I think a lot of other people do too.I like !in and !is.I propose that the word not, become an operator on operators.I don't like it. - It's more typing. - "!" already means "not" to me (in this context). - I read "!is" as "not is" and can't see an advantage to having "is not" instead. (I don't see why it has to be correct english) Regan
Apr 03 2006
On 2006-04-03 22:24:39 -0700, "Regan Heath" <regan netwin.co.nz> said:On Mon, 3 Apr 2006 20:34:24 -0700, S. Chancellor <dnewsgr mephit.kicks-ass.org> wrote:!is is ugly and hard to read, code is supposed to be beautiful.I really really hate the !in, !is syntax. I think a lot of other people do too.I like !in and !is.I propose that the word not, become an operator on operators.I don't like it. - It's more typing. - "!" already means "not" to me (in this context). - I read "!is" as "not is" and can't see an advantage to having "is not" instead. (I don't see why it has to be correct english) Regan
Apr 04 2006
On Tue, 4 Apr 2006 06:03:39 -0700, S. Chancellor <dnewsgr mephit.kicks-ass.org> wrote:On 2006-04-03 22:24:39 -0700, "Regan Heath" <regan netwin.co.nz> said:I disagree on both points.On Mon, 3 Apr 2006 20:34:24 -0700, S. Chancellor <dnewsgr mephit.kicks-ass.org> wrote:!is is ugly and hard to readI really really hate the !in, !is syntax. I think a lot of other people do too.I like !in and !is.I propose that the word not, become an operator on operators.I don't like it. - It's more typing. - "!" already means "not" to me (in this context). - I read "!is" as "not is" and can't see an advantage to having "is not" instead. (I don't see why it has to be correct english) Regancode is supposed to be beautiful.code is not supposed to be english, it's supposed to be code. code _is_ beautiful, english is not. Regan
Apr 04 2006
On Wed, 05 Apr 2006 07:37:44 +1000, Regan Heath <regan netwin.co.nz> wrote:On Tue, 4 Apr 2006 06:03:39 -0700, S. Chancellor <dnewsgr mephit.kicks-ass.org> wrote:I disagree with Regan and agree with S.!is is ugly and hard to readI disagree on both points.While that may be true, code is also meant to be easy to read by humans. My opinion is that keywords that are a combination of letters and symbols are contrary to human reading expectations and thus these decrease legibility. To overcome this, people need time to become accustomed to them before reading code for them becomes easier. My guess is that most people who first come to read D code that contains "!is" will have a momentary pause, but after a few repetitions will see it as no more 'confusing' than seeing "e.g." in standard English text. -- Derek Parnell Melbourne, Australiacode is supposed to be beautiful.code is not supposed to be english, it's supposed to be code. code _is_ beautiful, english is not.
Apr 04 2006
Clearly you've never read Yeats, Auden or Eliot. Frankly they make English more beautiful than any code I've seen.code is supposed to be beautiful.code is not supposed to be english, it's supposed to be code. code _is_ beautiful, english is not.
Apr 04 2006
On Tue, 4 Apr 2006 23:13:29 +0100, John C <johnch_atms hotmail.com> wrote:In visual appearance or actual meaning? I think code and writing can be compared in similar terms, i.e. does it get it's point across, does it do so elegantly, etc. However the actualy thing you measure to detemine those factors is different in each case. i.e. in the case of code whitespace in the right places can make the point of the code clearer.. I think it has less impact on writing. I could be wrong. In either case I think OP was referring to visual appearance of the actual characters in combination. This is obviously affected by the font used (as I suggested in another post) and (as Derek mentions) what you're used to. ReganClearly you've never read Yeats, Auden or Eliot. Frankly they make English more beautiful than any code I've seen.code is supposed to be beautiful.code is not supposed to be english, it's supposed to be code. code _is_ beautiful, english is not.
Apr 04 2006
"S. Chancellor" <dnewsgr mephit.kicks-ass.org> wrote in message news:e0spgo$2jvr$1 digitaldaemon.com...Foo not is null Foo not in BarEw.Foo not == Bar Foo not <= BarHow about Foo not equal to Bar Foo not less than or equal to Bar While you're at it? ;) Terseness is both a curse and a blessing of C-style syntax...
Apr 03 2006
On Tue, 4 Apr 2006 01:59:59 -0400, Jarrett Billingsley wrote:Terseness is both a curse and a blessing of C-style syntax...A language that I use daily (Progress 4GL) not only has the standard operators defined in terms of symbol characters etc... is also has them defined as ... eq ne gt lt ge le so one can write code such as for each Customer where balance gt 1000 -- Derek (skype: derek.j.parnell) Melbourne, Australia "Down with mediocracy!" 4/04/2006 4:10:11 PM
Apr 03 2006
Derek Parnell wrote:A language that I use daily (Progress 4GL) not only has the standard operators defined in terms of symbol characters etc... is also has them defined as ... eq ne gt lt ge le so one can write code such as for each Customer where balance gt 1000The same is also used in Perl and in PPC assembler. Probably lots of other places, as well. I like them. --anders
Apr 04 2006
Derek Parnell wrote:A language that I use daily (Progress 4GL) not only has the standard operators defined in terms of symbol characters etc... is also has them defined as ... eq neThis could work for "is" and "not is" too, just that it would end up as being Python ? I don't mean "is not" here, but http://tinyurl.com/nsm5u ;-) --anders
Apr 04 2006
Derek Parnell wrote:On Tue, 4 Apr 2006 01:59:59 -0400, Jarrett Billingsley wrote:Eewww.. -- Bruno Medeiros - CS/E student http://www.prowiki.org/wiki4d/wiki.cgi?BrunoMedeiros#DTerseness is both a curse and a blessing of C-style syntax...A language that I use daily (Progress 4GL) not only has the standard operators defined in terms of symbol characters etc... is also has them defined as ... eq ne gt lt ge le so one can write code such as for each Customer where balance gt 1000
Apr 04 2006
On 2006-04-03 22:59:59 -0700, "Jarrett Billingsley" <kb3ctd2 yahoo.com> said:"S. Chancellor" <dnewsgr mephit.kicks-ass.org> wrote in message news:e0spgo$2jvr$1 digitaldaemon.com...I didn't say I wanted to program in AppleScript. :P I hate mixing symbols and words. This is terrible. I'd rather redefine all the equal set and comparison operators. The whole point of the is-operator is equivalence, unfortunately there's no triple bar symbol. -S.Foo not is null Foo not in BarEw.Foo not == Bar Foo not <= BarHow about Foo not equal to Bar Foo not less than or equal to Bar While you're at it? ;) Terseness is both a curse and a blessing of C-style syntax...
Apr 04 2006
S. Chancellor wrote:I didn't say I wanted to program in AppleScript. :P I hate mixing symbols and words. This is terrible. I'd rather redefine all the equal set and comparison operators. The whole point of the is-operator is equivalence, unfortunately there's no triple bar symbol.Sure there is. ≡ in Unicode (\u2261), or === in plain ASCII. It's just that it was removed from the language in DMD 0.126 ? But I don't really see the point of bringing the old thread up ? It's even more futile than the whole "Boolean wars" thing was... If you don't like !is, then !do use it ? I don't think it'll change. It's just a kludge to fill a place for the "TOKnotidentity" token. *I* hate the ireal and creal types, but those are staying as well... Is it important enough to choose another language for ? Not to me. Then again I cheated, by just going back to the bad old C syntax. Just like you, I don't think I would have liked the "!is" either. --anders PS. My own suggestion was ~is, which works the same as ~this does. Was slightly more readable, but still a bit hard on the brain.
Apr 04 2006
Anders F Björklund wrote:S. Chancellor wrote:If D really _demands_ source code to be in UTF, then there is no excuse for avoiding single-character operators like "≡". Further, if a computer system is able to provide this UTF character set for source code writing, then one is _allowed_ to assume it can print them on the printer, too. Therefore, it is incongruous to avoid these characters as potential operators, while still demanding that D only be implemented on 32-bit systems. (We really can assume that from today on, any system purporting to be 32-bit, supports at least UTF.) --- One neat detail in the language definition would be that any "non US-ASCII" single or double character "operator" may actually be defined by the user, or in a custom library. Of course, any well-defined counter argumets are invited here.I didn't say I wanted to program in AppleScript. :P I hate mixing symbols and words. This is terrible. I'd rather redefine all the equal set and comparison operators. The whole point of the is-operator is equivalence, unfortunately there's no triple bar symbol.Sure there is. ≡ in Unicode (\u2261), or === in plain ASCII. It's just that it was removed from the language in DMD 0.126 ?
Apr 04 2006
On Wed, 05 Apr 2006 01:23:03 +0300, Georg Wrede <georg.wrede nospam.org> wrote:Anders F Björklund wrote:Except that they're not easily acessable on a common/standard keyboard, right? ReganS. Chancellor wrote:If D really _demands_ source code to be in UTF, then there is no excuse for avoiding single-character operators like "≡".I didn't say I wanted to program in AppleScript. :P I hate mixing symbols and words. This is terrible. I'd rather redefine all the equal set and comparison operators. The whole point of the is-operator is equivalence, unfortunately there's no triple bar symbol.Sure there is. ≡ in Unicode (\u2261), or === in plain ASCII. It's just that it was removed from the language in DMD 0.126 ?
Apr 04 2006
On Wed, 05 Apr 2006 10:31:04 +1200, Regan Heath wrote:On Wed, 05 Apr 2006 01:23:03 +0300, Georg Wrede <georg.wrede nospam.org> wrote:What? You mean you're *not* using the standard 473-key keyboard? How strange !? -- Derek (skype: derek.j.parnell) Melbourne, Australia "Down with mediocracy!" 5/04/2006 9:54:22 AMAnders F Björklund wrote:Except that they're not easily acessable on a common/standard keyboard, right?S. Chancellor wrote:If D really _demands_ source code to be in UTF, then there is no excuse for avoiding single-character operators like "≡".I didn't say I wanted to program in AppleScript. :P I hate mixing symbols and words. This is terrible. I'd rather redefine all the equal set and comparison operators. The whole point of the is-operator is equivalence, unfortunately there's no triple bar symbol.Sure there is. ≡ in Unicode (\u2261), or === in plain ASCII. It's just that it was removed from the language in DMD 0.126 ?
Apr 04 2006
Derek Parnell wrote:Regan Heath wrote:If somebody is able to produce "≡", then let him define it. All we need is some suitable syntax. define ≡ opMyEqual; // or something like this I admit, this idea is not yet implementable as such: some operators may not be strictly binary, and other such issues. And I'm definitely not talking D 1.0 here. But still. Such a character would of course only be used in that particular application, and thus probably be developed by a group of people who can tell each other how to produce this character. Or they can copy/paste it (just as I did, without even bothering to search for ways of actually typing it). However, many very illustrative UTF characters do exist. Math, statistics, programming, logic, etc... could benefit from their use in source code. And if they were user-defined-only (as opposed to ever becoming included in the actual D spec), issues of right or wrong usage should be on a par with issues around variable names. (I.e. any idiot can use variable names written in Thai or Russian characters, but it's still not too common, and never will be.) --- I'm not really pursuing this issue as something First Priority, or Essential. It's more like, if we don't accept this, then what's the use of accepting any at all non-USASCII source code (outside of string literals)?Georg WredeWhat? You mean you're *not* using the standard 473-key keyboard? How strange !?Anders F Björklund wrote:Except that they're not easily acessable on a common/standard keyboard, right?S. Chancellor wrote:If D really _demands_ source code to be in UTF, then there is no excuse for avoiding single-character operators like "≡".I didn't say I wanted to program in AppleScript. :P I hate mixing symbols and words. This is terrible. I'd rather redefine all the equal set and comparison operators. The whole point of the is-operator is equivalence, unfortunately there's no triple bar symbol.Sure there is. ≡ in Unicode (\u2261), or === in plain ASCII. It's just that it was removed from the language in DMD 0.126 ?
Apr 04 2006
On Wed, 05 Apr 2006 03:37:40 +0300, Georg Wrede wrote:Derek Parnell wrote:Regan Heath wrote:Georg WredeI'm sorry Georg, I wasn't disapproving of your idea, I was just making a lame joke about needing a large keyboard to make such an idea easy-to-use. In fact, I like the idea of being able to define new operators, but then I love Forth too ;-) -- Derek (skype: derek.j.parnell) Melbourne, Australia "Down with mediocracy!" 5/04/2006 10:55:09 AMIf somebody is able to produce "¡Ý", then let him define it. All we need is some suitable syntax.What? You mean you're *not* using the standard 473-key keyboard? How strange !?If D really _demands_ source code to be in UTF, then there is no excuse for avoiding single-character operators like "¡Ý".Except that they're not easily acessable on a common/standard keyboard, right?
Apr 04 2006
Georg Wrede wrote:An old feature request was that D should allow Unicode operators, as an *alternative* to the ASCII operators. But it didn't catch on ? http://www.prowiki.org/wiki4d/wiki.cgi?FeatureRequestList/UnicodeOperators (Somehow these things are always treated as replacements, not add-ons)If somebody is able to produce "≡", then let him define it. All we need is some suitable syntax. define ≡ opMyEqual; // or something like this I admit, this idea is not yet implementable as such: some operators may not be strictly binary, and other such issues. And I'm definitely not talking D 1.0 here. But still.What? You mean you're *not* using the standard 473-key keyboard? How strange !?Except that they're not easily acessable on a common/standard keyboard, right?Sure there is. ≡ in Unicode (\u2261), or === in plain ASCII. It's just that it was removed from the language in DMD 0.126 ?If D really _demands_ source code to be in UTF, then there is no excuse for avoiding single-character operators like "≡".Such a character would of course only be used in that particular application, and thus probably be developed by a group of people who can tell each other how to produce this character. Or they can copy/paste it (just as I did, without even bothering to search for ways of actually typing it).I just selected it from the Unicode input helper: http://www.algonet.se/~afb/d/unicode-palette.pngI'm not really pursuing this issue as something First Priority, or Essential. It's more like, if we don't accept this, then what's the use of accepting any at all non-USASCII source code (outside of string literals)?I believe that D in practice is an ASCII language. That's OK with me. --anders
Apr 05 2006
On Wed, 05 Apr 2006 04:08:08 -0400, Anders F Björklund <afb algonet.se> wrote:An old feature request was that D should allow Unicode operators, as an *alternative* to the ASCII operators. But it didn't catch on ? http://www.prowiki.org/wiki4d/wiki.cgi?FeatureRequestList/UnicodeOperators (Somehow these things are always treated as replacements, not add-ons)Not everyone supports unicode very well. What happens when I try looking at your source code and I see funny boxes or question marks.. it'd be fine in string literals, but if it's part of the program flow, I'd be lost.
Apr 05 2006
Chris Miller wrote:On Wed, 05 Apr 2006 04:08:08 -0400, Anders F Björklund <afb algonet.se> wrote:Isn't that point defeated by the fact that we have Unicode identifiers?An old feature request was that D should allow Unicode operators, as an *alternative* to the ASCII operators. But it didn't catch on ? http://www.prowiki.org/wiki4d/wiki.cgi?FeatureRequestList/UnicodeOperators (Somehow these things are always treated as replacements, not add-ons)Not everyone supports unicode very well. What happens when I try looking at your source code and I see funny boxes or question marks.. it'd be fine in string literals, but if it's part of the program flow, I'd be lost.
Apr 05 2006
Deewiant wrote:Chris Miller wrote:http://www.prowiki.org/wiki4d/wiki.cgi?FeatureRequestList/UnicodeOperatorsOn Wed, 05 Apr 2006 04:08:08 -0400, Anders F Björklund <afb algonet.se> wrote:An old feature request was that D should allow Unicode operators, as an *alternative* to the ASCII operators. But it didn't catch on ?Not really, as you currently know that identifiers can be Unicode, but not the operators. I agree that Unicode identifiers can be difficult to read if some of the characters are missing in the font, but at least you'd still know which operations were performed on them.Isn't that point defeated by the fact that we have Unicode identifiers?(Somehow these things are always treated as replacements, not add-ons)Not everyone supports unicode very well. What happens when I try looking at your source code and I see funny boxes or question marks.. it'd be fine in string literals, but if it's part of the program flow, I'd be lost.
Apr 05 2006
Lars Ivar Igesund wrote:Deewiant wrote:The problem is that, even now, in the worst case you can get something that looks like this: ??? += ???; for (?? = ???; ??? < ?; ?.???()) { ???.?.???(??, ???); if (??.?()) writefln(??? * (?-??)); } While this is, of course, quite unlikely, I doubt that changing the operators in the above to "?" decreases readability very much. <g>Chris Miller wrote:http://www.prowiki.org/wiki4d/wiki.cgi?FeatureRequestList/UnicodeOperatorsOn Wed, 05 Apr 2006 04:08:08 -0400, Anders F Björklund <afb algonet.se> wrote:An old feature request was that D should allow Unicode operators, as an *alternative* to the ASCII operators. But it didn't catch on ?Not really, as you currently know that identifiers can be Unicode, but not the operators. I agree that Unicode identifiers can be difficult to read if some of the characters are missing in the font, but at least you'd still know which operations were performed on them.Isn't that point defeated by the fact that we have Unicode identifiers?(Somehow these things are always treated as replacements, not add-ons)Not everyone supports unicode very well. What happens when I try looking at your source code and I see funny boxes or question marks.. it'd be fine in string literals, but if it's part of the program flow, I'd be lost.
Apr 05 2006
"Deewiant" <deewiant.doesnotlike.spam gmail.com> wrote in message news:e110jq$31dh$1 digitaldaemon.com...??? += ???; for (?? = ???; ??? < ?; ?.???()) { ???.?.???(??, ???); if (??.?()) writefln(??? * (?-??)); }Don't forget: ? = ???? ? ??? : 0; The ternary ?: would be impossible to spot ;)
Apr 05 2006
Chris Miller wrote:I thought D only supported Unicode platforms ? (it only does for input/output, for instance) Anyway, where there is use there is abuse I guess... Maybe it's good that there's no Unicode operators. I for one (usually) keep my code ASCII and English. --andersAn old feature request was that D should allow Unicode operators, as an *alternative* to the ASCII operators. But it didn't catch on ?Not everyone supports unicode very well. What happens when I try looking at your source code and I see funny boxes or question marks.. it'd be fine in string literals, but if it's part of the program flow, I'd be lost.
Apr 05 2006
Georg Wrede wrote:Anders F Björklund wrote:I have an utf-enabled email-client but that character is not present in my standard font. I only see a nice rectangle :)S. Chancellor wrote:If D really _demands_ source code to be in UTF, then there is no excuse for avoiding single-character operators like "≡".I didn't say I wanted to program in AppleScript. :P I hate mixing symbols and words. This is terrible. I'd rather redefine all the equal set and comparison operators. The whole point of the is-operator is equivalence, unfortunately there's no triple bar symbol.Sure there is. ≡ in Unicode (\u2261), or === in plain ASCII. It's just that it was removed from the language in DMD 0.126 ?
Apr 05 2006
Sorry, I don't agree. != has been in C for ages and any C programmer should therefore understand !in or !is. Unlike in natural language text, source code does ! become more readable when using words. It may slightly help the newbie, but it will get in the way for everyday use. The problem of Perl, for example, is not that it uses cryptic operators, but that it uses too many, so that it takes a long time to know all of them. the die-hard Perl users love that because it really improves productivity, but any outsider is left in the rain. For D, it is important to find the right measure which lies somewhere in between Perl and Cobol: http://www.csis.ul.ie/COBOL/Exercises/Exm-AcmeStockReorder/Prg-AcmeStockReorder.htm
Apr 03 2006
Norbert Nemec wrote:Sorry, I don't agree. != has been in C for ages and any C programmer should therefore understand !in or !is. Unlike in natural language text, source code does ! become more readable when using words. It may slightly help the newbie, but it will get in the way for everyday use.Ehrm, wasn't '===' changed to 'is' exactly because it was more readable? I know many people that prefer 'not' over '!', 'and' over '&&', etc etc. Originally I didn't see a problem of adding them as alternative syntax, but now I know that it would somehow mean the D originals have to go... So requiring '!is' is bad enough, without making it 'not is' - or worse. It isn't very beautiful, but then I don't think that was a design goal ? --anders
Apr 04 2006
Anders F Björklund wrote:Norbert Nemec wrote:I thought it was because === was almost indistinguishable from == with some international fonts.Sorry, I don't agree. != has been in C for ages and any C programmer should therefore understand !in or !is. Unlike in natural language text, source code does ! become more readable when using words. It may slightly help the newbie, but it will get in the way for everyday use.Ehrm, wasn't '===' changed to 'is' exactly because it was more readable?I know many people that prefer 'not' over '!', 'and' over '&&', etc etc. Originally I didn't see a problem of adding them as alternative syntax, but now I know that it would somehow mean the D originals have to go... So requiring '!is' is bad enough, without making it 'not is' - or worse. It isn't very beautiful, but then I don't think that was a design goal ? --anders
Apr 04 2006
Don Clugston wrote:Yes, I guess that would qualify as "unreadable" when using such a font. :-) --andersEhrm, wasn't '===' changed to 'is' exactly because it was more readable?I thought it was because === was almost indistinguishable from == with some international fonts.
Apr 04 2006
On 2006-04-04 01:46:01 -0700, Anders F Björklund <afb algonet.se> said:Don Clugston wrote:!is is pretty hard to read to me. I hate having the ! next to the i.Yes, I guess that would qualify as "unreadable" when using such a font. :-) --andersEhrm, wasn't '===' changed to 'is' exactly because it was more readable?I thought it was because === was almost indistinguishable from == with some international fonts.
Apr 04 2006
"S. Chancellor" <dnewsgr mephit.kicks-ass.org> wrote in message news:e0trg6$11dp$4 digitaldaemon.com...!is is pretty hard to read to me. I hate having the ! next to the i.It's easy to read for me. And for most people, apparently, considering that there hasn't been a topic on the issue since !is was implemented.
Apr 04 2006
On 2006-04-03 23:29:54 -0700, Norbert Nemec <Norbert Nemec-online.de> said:Sorry, I don't agree. != has been in C for ages and any C programmer should therefore understand !in or !is. Unlike in natural language text, source code does ! become more readable when using words. It may slightly help the newbie, but it will get in the way for everyday use. The problem of Perl, for example, is not that it uses cryptic operators, but that it uses too many, so that it takes a long time to know all of them. the die-hard Perl users love that because it really improves productivity, but any outsider is left in the rain. For D, it is important to find the right measure which lies somewhere in between Perl and Cobol: http://www.csis.ul.ie/COBOL/Exercises/Exm-AcmeStockReorder/Prg-AcmeStockReorder.htmTheissue !is that !is is ! easy to understand, the issue is that it's a bad solution to an artificial problem. Have word based operators, or don't. The reason 'is' was picked is it's used in other languages for equivalence. I don't see !is anywhere. If we're not going to stick with the standard solution why not go to some other symbol for equivalence. Hell, we could just write : Foo Bar Not to mention that i's and !'s should never be next to each other: !i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i -S.
Apr 04 2006
On Tue, 4 Apr 2006 06:13:23 -0700, S. Chancellor <dnewsgr mephit.kicks-ass.org> wrote:Not to mention that i's and !'s should never be next to each other: !i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!i!iWhat font are you using, the above is perfectly clear to me, ! and i look very different in my font (which I assume is times new roman - cos I have no option to change it here in Opera - that a quick search found, anyway). Regan
Apr 04 2006
On Wed, 05 Apr 2006 07:40:32 +1000, Regan Heath <regan netwin.co.nz> wrote:I have no option to change it here in Opera - that a quick search found, anyway).Select the 'Tools' menu. Select 'Preferences...' Select the 'Advanced' tab. Click on 'Fonts' in the left-hand-side panel. Click on the Type 'Interface display e-mail'. Click on the 'Choose' button to bring up the font dialog. -- Derek Parnell Melbourne, Australia
Apr 04 2006
On Wed, 05 Apr 2006 08:01:57 +1000, Derek Parnell <derek psych.ward> wrote:On Wed, 05 Apr 2006 07:40:32 +1000, Regan Heath <regan netwin.co.nz> wrote:Ta. It's "Courier New" then. ReganI have no option to change it here in Opera - that a quick search found, anyway).Select the 'Tools' menu. Select 'Preferences...' Select the 'Advanced' tab. Click on 'Fonts' in the left-hand-side panel. Click on the Type 'Interface display e-mail'. Click on the 'Choose' button to bring up the font dialog.
Apr 04 2006
S. Chancellor wrote:I really really hate the !in, !is syntax. I think a lot of other people do too.I do too. Hmm, does "!in" even exist ?I propose that the word not, become an operator on operators. For example: Foo not is null Foo not in BarBut this just looks just as horrible ? Back in the day it was suggested that the Foo !== null syntax was changed into !(Foo is null), so I guess you can use that ? I just gave up and converted it to !Foo... Boolean be damned. --anders
Apr 04 2006
Anders F Björklund wrote:S. Chancellor wrote:And that would be a resounding NO.I really really hate the !in, !is syntax. I think a lot of other people do too.I do too. Hmm, does "!in" even exist ?I propose that the word not, become an operator on operators. For example: Foo not is null Foo not in BarBut this just looks just as horrible ? Back in the day it was suggested that the Foo !== null syntax was changed into !(Foo is null), so I guess you can use that ? I just gave up and converted it to !Foo... Boolean be damned. --anders
Apr 04 2006
On 2006-04-04 00:06:06 -0700, Anders F Björklund <afb algonet.se> said:S. Chancellor wrote:I liked the other syntax better. But this isn't perl, there shouldn't aliased operators. IMO.I really really hate the !in, !is syntax. I think a lot of other people do too.I do too. Hmm, does "!in" even exist ?I propose that the word not, become an operator on operators. For example: Foo not is null Foo not in BarBut this just looks just as horrible ? Back in the day it was suggested that the Foo !== null syntax was changed into !(Foo is null), so I guess you can use that ? I just gave up and converted it to !Foo... Boolean be damned. --anders
Apr 04 2006
S. Chancellor wrote:I really really hate the !in, !is syntax.I don't. I actually quite like it.I propose that the word not, become an operator on operators.I sure hope it doesn't.
Apr 04 2006
Mike Parker wrote:S. Chancellor wrote:I agree with Mike here. On both accounts.I really really hate the !in, !is syntax.I don't. I actually quite like it.I propose that the word not, become an operator on operators.I sure hope it doesn't.
Apr 04 2006
Lars Ivar Igesund wrote:Mike Parker wrote:So do I.S. Chancellor wrote:I agree with Mike here. On both accounts.I really really hate the !in, !is syntax.I don't. I actually quite like it.I propose that the word not, become an operator on operators.I sure hope it doesn't.
Apr 04 2006