http://www.perlmonks.org?node_id=973332


in reply to Re^3: What operator should perl5porters use for safe dereferencing?
in thread What operator should perl5porters use for safe dereferencing?

The main problem I have with ~> is the change in shift key. The ~ is on the left side of the keyboard (at least my US-style keyboard), so touch typists will use the right shift key. > is on the right, thus the use of the left shift key. tchrist's "Twister" moniker comes in to play here - try typing it out a few times to see how easy/difficult it is. Maybe for hunt-and-peck typists there won't be much difference. For touch typists, we could come up with an alternative that was less discordant (such as ->>).

The fact that a quick glance at code wouldn't always tell the difference between -> and ~> is, in my opinion, both a positive and a negative. Positive in that they are so tightly related and often that's good enough, but negative in having to mentally switch gears to actually pay attention and notice it when it matters.

  • Comment on Re^4: What operator should perl5porters use for safe dereferencing?
  • Download Code

Replies are listed 'Best First'.
Re^5: What operator should perl5porters use for safe dereferencing?
by Ralesk (Pilgrim) on May 30, 2012 at 23:08 UTC

    Hmm, maybe I’m using my keyboard wrong, but I’m one of those people who more often than not use the right shift (the left being tiny due to the European style 102-key key layout). Even if I had a preference for the left shift key though, the thing would be the same: press shift, press one of the keys, press the other key with the other hand, release shift. If anything, -> is ever so slightly harder to type because the precise timing needed between the two keystrokes, whereas ~>’s both characters are on the same shift level on English layouts at least.

    My problem with ~> is that on certain font sizes with certain fonts and certain hinting settings, FreeType makes the tilde look like a straight bar.

      Hmm, I learned touch typing, but I no longer venture past qwerty by touch, even now that I've lost my numpad -- kinda weird
Re^5: What operator should perl5porters use for safe dereferencing?
by DrHyde (Prior) on May 31, 2012 at 10:18 UTC

      I used to love typing on those :) I also really liked how the mouse was plugged into the keyboard in the PS/2 version, making it a much more comfortable experience than PCs at the time with not-long-enough mouse cables to reach the box on the ground.

        On the USB version there are *three* ports on the keyboard, so you can plug in a mouse, a Flash memory stick, and even charge your phone!
Re^5: What operator should perl5porters use for safe dereferencing?
by Boldra (Deacon) on May 31, 2012 at 07:04 UTC
    An excellent point. I hope it gets taken into consideration.


    - Boldra
Re: What operator should perl5porters use for safe dereferencing?
by jonadab (Parson) on Jun 13, 2012 at 05:07 UTC
    The ~ is on the left side of the keyboard (at least my US-style keyboard), so touch typists will use the right shift key...

    There are people who use the right shift key? Seriously?

    Huh. I use the right shift key about as often as the right alt and right ctrl keys -- which is to say, somebody could sabotage those keys as an April Fools joke so that pressing them does nothing, and it could be five years or more before I notice, depending on when I finally get around to cleaning out my keyboard thoroughly (as opposed to just quickly running an ISO long narrow object between the keys to get most of the hair out, which is what I usually do).