Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Python > Dollar sign ($) on foriegn keyboards? (prothon)

Reply
Thread Tools

Dollar sign ($) on foriegn keyboards? (prothon)

 
 
Mark Hahn
Guest
Posts: n/a
 
      04-20-2004
We are considering switching to the dollar sign ($) for self, instead of the
period ( . ) we are using now in Prothon. Ruby uses the at-sign (@) for
self, but our new usage of self also includes replacing the period for some
attribute references, as in obj$func() versus obj.func(), and too many
programs treat that as an email address and screw it up. Also the S in the
symbol $ reminds one of the S in $elf.

Can people from outside the U.S. tell me if typing the dollar sign often
would be a problem in writing code? Is it available and somewhat easy to
type on international keyboards?


 
Reply With Quote
 
 
 
 
Roel Schroeven
Guest
Posts: n/a
 
      04-20-2004
Mark Hahn wrote:
> Can people from outside the U.S. tell me if typing the dollar sign often
> would be a problem in writing code? Is it available and somewhat easy to
> type on international keyboards?


Belgian azerty: no problem. Easier to type, in fact, than several other
symbols that are frequently used while programming, e.g. []{}_.

--
"Codito ergo sum"
Roel Schroeven
 
Reply With Quote
 
 
 
 
LB
Guest
Posts: n/a
 
      04-20-2004

"
> Can people from outside the U.S. tell me if typing the dollar sign often
> would be a problem in writing code? Is it available and somewhat easy to
> type on international keyboards?
>

$ is a shift-key on italian standard keyboard.

LB


 
Reply With Quote
 
=?ISO-8859-1?Q?Petter_Holmstr=F6m?=
Guest
Posts: n/a
 
      04-20-2004
Mark Hahn wrote:
> Can people from outside the U.S. tell me if typing the dollar sign often
> would be a problem in writing code? Is it available and somewhat easy to
> type on international keyboards?
>


Finnish/Swedish keyboards: No problems (AltGr + 4)

-Petter-
 
Reply With Quote
 
Peter Maas
Guest
Posts: n/a
 
      04-20-2004
LB wrote:
> $ is a shift-key on italian standard keyboard.


Also on german standard keyboard.

Mit freundlichen Gruessen,

Peter Maas

--
-------------------------------------------------------------------
Peter Maas, M+R Infosysteme, D-52070 Aachen, Hubert-Wienen-Str. 24
Tel +49-241-93878-0 Fax +49-241-93878-20 eMail http://www.velocityreviews.com/forums/(E-Mail Removed)
-------------------------------------------------------------------
 
Reply With Quote
 
Hans-Peter Schroecker
Guest
Posts: n/a
 
      04-20-2004
On Tue, 20 Apr 2004 10:04:35 +0200, Peter Maas <(E-Mail Removed)> wrote:
> LB wrote:
>> $ is a shift-key on italian standard keyboard.

>
> Also on german standard keyboard.


Just as on the Japanese notebook in front of me.

Hans-Peter Schröcker
 
Reply With Quote
 
Peter Otten
Guest
Posts: n/a
 
      04-20-2004
Mark Hahn wrote:

> We are considering switching to the dollar sign ($) for self, instead of
> the
> period ( . ) we are using now in Prothon. Ruby uses the at-sign (@) for
> self, but our new usage of self also includes replacing the period for
> some attribute references, as in obj$func() versus obj.func(), and too
> many
> programs treat that as an email address and screw it up. Also the S in
> the symbol $ reminds one of the S in $elf.
>
> Can people from outside the U.S. tell me if typing the dollar sign often
> would be a problem in writing code? Is it available and somewhat easy to
> type on international keyboards?


In Germany every serious programmer has to switch to the American layout
anyway because of {}[]@\~| (all odd AltGr combinations). As this is no
problem on Windows and Linux(KDE) (how about the Mac?), I recommend against
making special character choices based on keyboard layout.

Apart from that obj$func() hurts my eye more than obj->func() and
obj!func(). As always, Python shines here with its obj.func()

Peter
 
Reply With Quote
 
Joe Mason
Guest
Posts: n/a
 
      04-20-2004
In article <c62m70$2hu$06$(E-Mail Removed)-online.com>, Peter Otten wrote:
> Mark Hahn wrote:
>
>> We are considering switching to the dollar sign ($) for self, instead of
>> the
>> period ( . ) we are using now in Prothon. Ruby uses the at-sign (@) for


<snip>

> Apart from that obj$func() hurts my eye more than obj->func() and
> obj!func(). As always, Python shines here with its obj.func()


I believe the suggestion is "$.func()" instead of "self.func()" (the
Python way) or just ".func()" (the earlier Prothon way). Or possibly
the suggestion is for "$func()", although I like $.func() much better.

(I like this better than the ., though I still have no problem with
writing self all the time, so I prefer sticking to the Python way. It
solves my main problem with ., which is when you do have to pass self
explicitly. "function_call(param1, ., parm2)" is much more confusing
than "function_call(param1, $, param2)".)

Joe
 
Reply With Quote
 
Hugh Macdonald
Guest
Posts: n/a
 
      04-20-2004
On Mon, 19 Apr 2004 23:22:10 -0700
"Mark Hahn" <(E-Mail Removed)> wrote:

> Can people from outside the U.S. tell me if typing the dollar sign
> often would be a problem in writing code? Is it available and
> somewhat easy to type on international


Anyone who writes a language like Perl or PHP would use it a lot anyway (all variables start with a symbol, usually $)

--
Hugh Macdonald
The Moving Picture Company

 
Reply With Quote
 
Peter Otten
Guest
Posts: n/a
 
      04-20-2004
Joe Mason wrote:

> In article <c62m70$2hu$06$(E-Mail Removed)-online.com>, Peter Otten wrote:
>> Mark Hahn wrote:
>>
>>> We are considering switching to the dollar sign ($) for self, instead of
>>> the
>>> period ( . ) we are using now in Prothon. Ruby uses the at-sign (@) for

>
> <snip>
>
>> Apart from that obj$func() hurts my eye more than obj->func() and
>> obj!func(). As always, Python shines here with its obj.func()

>
> I believe the suggestion is "$.func()" instead of "self.func()" (the
> Python way) or just ".func()" (the earlier Prothon way). Or possibly
> the suggestion is for "$func()", although I like $.func() much better.


I skimmed too lightly over the first paragraph and missed that - but still
there is the obj$func() example in Mark's post, and with my Python mindset
(I didn't follow the Prothon discussion closely) I cannot figure out what
that is supposed to mean.

> (I like this better than the ., though I still have no problem with
> writing self all the time, so I prefer sticking to the Python way. It
> solves my main problem with ., which is when you do have to pass self
> explicitly. "function_call(param1, ., parm2)" is much more confusing
> than "function_call(param1, $, param2)".)


[OT] Seems to happen all the time with Python - try to simplify at some
point and you pay twice elsewhere. Prothon will have a hard time occupying
a local optimum in beauty/simplicity/usefulness that is both near and
better than Python. This starts with the name, by the way - it evokes the
association of prothotype, which looks quite, er, ungreek

Peter

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
u'\N{dollar sign}' belred Python 1 05-21-2009 01:45 AM
dollar sign literals Jason Williams Perl Misc 8 07-11-2007 02:35 AM
What does dollar sign in ClassName$.class mean? Marcus Leon Java 1 06-07-2006 09:44 PM
ASP.NET: dollar sign ($) changed to undisplayable characters Norman Yuan ASP .Net 0 12-08-2005 11:17 PM
Why use dollar sign $ for variables Dennis Walter Perl Misc 21 07-14-2004 08:01 PM



Advertisments