[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.ruby

Umlauts in source code

Bertram Scharpf

1/20/2005 11:46:00 AM

Hi,

on my Debian Linux this problem doesn't appear. Yet, it is
reported to me that on SuSE Linux, the standard Ruby
installation has problems with reading in source files that
contain umlauts (characters >= '\x80').

A string 'ü' produces a syntax error, a regexp /ü/ will
report a "premature end" of the regexp.

I made experiments with $KCODE but I didn't achieve to
reproduce the reported misbehaviour.

I could enter '\xfc' everywhere I need a 'ü' but that is
annoying.

What do I have to do to solve this correctly?

Thanks in advance,

Bertram

--
Bertram Scharpf
Stuttgart, Deutschland/Germany
http://www.bertram-...


10 Answers

Yukihiro Matsumoto

1/20/2005 1:58:00 PM

0

Hi,

In message "Re: Umlauts in source code"
on Thu, 20 Jan 2005 20:45:49 +0900, Bertram Scharpf <lists@bertram-scharpf.de> writes:

|on my Debian Linux this problem doesn't appear. Yet, it is
|reported to me that on SuSE Linux, the standard Ruby
|installation has problems with reading in source files that
|contain umlauts (characters >= '\x80').

I think the difference is the default KCODE value in the compile time
configuration. One needs to set -Kn when he wants to put iso-8859
letters. The simple

#! /usr/bin/ruby -Kn

at the beginning of a file will do.

matz.


Bertram Scharpf

1/20/2005 5:40:00 PM

0

Hi,

Am Donnerstag, 20. Jan 2005, 22:58:05 +0900 schrieb Yukihiro Matsumoto:
> In message "Re: Umlauts in source code"
> on Thu, 20 Jan 2005 20:45:49 +0900, Bertram Scharpf <lists@bertram-scharpf.de> writes:
>
> |on my Debian Linux this problem doesn't appear. Yet, it is
> |reported to me that on SuSE Linux, the standard Ruby
> |installation has problems with reading in source files that
> |contain umlauts (characters >= '\x80').
>
> I think the difference is the default KCODE value in the compile time
> configuration. One needs to set -Kn when he wants to put iso-8859
> letters. The simple
>
> #! /usr/bin/ruby -Kn
>
> at the beginning of a file will do.

Ah, yes! As I noiticed in the meantime, SuSE sets $KCODE by
default to "UTF-8".

Bertram

--
Bertram Scharpf
Stuttgart, Deutschland/Germany
http://www.bertram-...


Bertram Scharpf

1/22/2005 4:51:00 PM

0

Hi,

Am Freitag, 21. Jan 2005, 02:40:07 +0900 schrieb Bertram Scharpf:
> > #! /usr/bin/ruby -Kn

I would like to propose a solution similar to that in Python
since

#!/usr/bin/env ruby -Kn

doesn't work. In Python, the second line is allowed to give
the character encoding:

#!/usr/bin/env python
# -*- coding: iso-8859-15 -*-

Or does anybody know a better solution?

Bertram

--
Bertram Scharpf
Stuttgart, Deutschland/Germany
http://www.bertram-...


ts

1/22/2005 5:03:00 PM

0

>>>>> "B" == Bertram Scharpf <lists@bertram-scharpf.de> writes:

B> Or does anybody know a better solution?

See [ruby-core:4192]

http://www.ruby-talk.org/cgi-bin/scat.rb/ruby/ruby...


Guy Decoux



Bertram Scharpf

1/22/2005 8:31:00 PM

0

Hi Guy,

Am Sonntag, 23. Jan 2005, 02:02:31 +0900 schrieb ts:
> >>>>> "B" == Bertram Scharpf <lists@bertram-scharpf.de> writes:
>
> B> Or does anybody know a better solution?
>
> See [ruby-core:4192]
>
> http://www.ruby-talk.org/cgi-bin/scat.rb/ruby/ruby...

Ah, thanks!

Bertram

--
Bertram Scharpf
Stuttgart, Deutschland/Germany
http://www.bertram-...


Steven Douglas

9/1/2009 1:16:00 PM

0

On Aug 31, 10:34 pm, tirebiter <dontspamme...@bigfoot.com> wrote:
>
> On Sep 1, 12:52 am, Steven Douglas <steven.doug...@rocketmail.com>
> wrote:
>
> > On Aug 31, 9:32 pm, tirebiter <dontspamme...@bigfoot.com> wrote:
>
> > > On Sep 1, 12:00 am, Steven Douglas <steven.doug...@rocketmail.com>
> > > wrote:
>
> > > > On Aug 29, 1:52 pm, tirebiter <dontspamme...@bigfoot.com> wrote:
>
> > > > > On Aug 27, 9:10 am, Steven Douglas <steven.doug...@rocketmail.com>
> > > > > wrote:
>
> > > > > > On Aug 26, 9:48 pm, tirebiter <dontspamme...@bigfoot.com> wrote:
>
> > > > > > > On Aug 27, 12:34 am, Steven Douglas <steven.doug...@rocketmail.com>
> > > > > > > wrote:
>
> > > > > > > > Jesus frequently spoke in parables. I don't take everything he said
> > > > > > > > literally, since it's obvious he often spoke figuratively.
>
> > > > > > > It just gets better and better.  You cherry-pick what you want to
> > > > > > > believe and turn a blind eye to the rest.
>
> > > > > > I've turned a blind eye to nothing. I just interpret it differently
> > > > > > than you do.
>
> > > > > And yet you still don't see what you are actually writing here.  This
> > > > > is supposed to be the literal and inerrant word of your god, and you
> > > > > have to INTERPRET it before it makes sense to you.  And after you've
> > > > > mangled it into what every mush that is palatable to you, you use it
> > > > > as the basis of your whole religious belief system.
>
> > > > Just because God is undetectable to you doesn't mean He's undetectable
> > > > to others.
>
> > > > > > > Or you just decide that the
> > > > > > > parts you find distasteful are simply intended to be taken
> > > > > > > figuratively so there's nothing there to worry your pretty little head
> > > > > > > about.
>
> > > > > > I'm not worried about anything, but what is it precisely that you'd
> > > > > > like me to be worried about?
>
> > > > > I'd be worried about why anyone would base their whole belief on a
>
> > > > You might be worried about it, but I'm not you.
>
> > > No you're not.  You're the guy who invents... er... interprets what
> > > his so-called god has supposedly said and done in order to make it the
> > > least bit palatable to believe in.
>
> > If you don't believe in God, why do you spend so much time concerned
> > with something you don't believe exists?
>
> It depends on the circumstances.  In this case, I enjoy watching
> christians rationalize away the massive defects in their religion via
> "interpretation".  It's a double joy when they judge other christians
> as being "true" or not based how they think all other christians
> should behave.  You've been quite the source of entertainment in both
> these areas.

All I did was comment on someone's flawed belief that Christians
should believe the world will end on December 21, 2012. There is no
reason for *any* Christian to believe that. So what is your point
again?
>
> Otherwise, I have very strong objections to the religious
> fundamentalists trying to return to the dark ages by making false
> claims that the United States is a christian nation, or that the
> evolution theory is some sort of plot against this mythical god, or
> the many other ways christians choose to marginalize anybody who
> disagrees with them.  In this regard, it is exactly as Thomas
> Jefferson attributed as saying, "The Price of Liberty is Eternal
> Vigilance".

I'll defend your right to believe as you choose. I'd stand with you
against anyone who tried to impose his belief on you. Is that clear?
>
> And on top of it all, this is an open discussion forum.  If you are so
> ill equipped to defend the basic foundation for your religious belief,

I think I did pretty well pointing out that Jesus said no man knows
what day the world will end. Anyone who thinks it will end on December
21, 2012, does not believe Jesus.
>
> go find some fundamentalist group that will shower you with chants of
> "praise jesus" everytime you judge the godless and untrue christians.

I didn't find your group. It found me. This thread is cross-posted to
several groups.

Dan Listermann

9/1/2009 2:30:00 PM

0


"Ralph" <mmman_90@yahoo.com> wrote in message
news:DMidne2rNbKqhQHXnZ2dnUVZ_gNi4p2d@giganews.com...
> Terry Cross wrote:
>> On Aug 31, 8:39 am, "Dan Listermann" <d...@listermann.com> wrote:
>>> "Free Lunch" <lu...@nofreelunch.us> wrote in message
>>>
>>> news:e1rn951h5r8371u8b9l7a4iq8u54ketpjs@4ax.com...
>>>
>>>
>>>
>>>> On Mon, 31 Aug 2009 11:02:47 -0400, "Dan Listermann"
>>>> <d...@listermann.com> wrote in alt.talk.creationism:
>>>>> "Free Lunch" <lu...@nofreelunch.us> wrote in message
>>>>> news:mpnn9594tk3j9hsectkoqp9lku2bur6h9f@4ax.com...
>>>>>> On Mon, 31 Aug 2009 06:10:48 -0700 (PDT), Werewolfy
>>>>>> <Werewol...@yahoo.co.uk> wrote in alt.talk.creationism:
>>>>>>> On 27 Aug, 14:10, Steven Douglas <steven.doug...@rocketmail.com>
>>>>>>> wrote:
>>>>>>> "Jesus frequently spoke in parables. I don't take everything he said
>>>>>>> literally, since it's obvious he often spoke figuratively."
>>>>>>> I wonder why He did that? I mean, He arrives on earth to inform his
>>>>>>> creations, to tell everyone about the ways of God..and yet he spoke
>>>>>>> in
>>>>>>> riddles, rather than in understandable 'yes' or 'no' simple speech.
>>>>>>> Like any politician, he never seems to answer any question, but
>>>>>>> simply
>>>>>>> makes some seemingly profound statement around the outskirts of the
>>>>>>> question...a statement that is frequently unintelligible.
>>>>>>> Why? He came to deliver his message. Why choose to do so in such an
>>>>>>> odd way. It reminds me of the digressions and subterfuge used by
>>>>>>> fake
>>>>>>> Mediums as they pass obscure messages from beyond the grave to
>>>>>>> relatives.
>>>>>>> Why speak in parables..what was the point of that, considering He
>>>>>>> was
>>>>>>> on Earth to spread 'the message'?
>>>>>> Maybe because the Jesus of the gospels was just a sockpuppet of the
>>>>>> people who were inventing the religion.
>>>>> Paul?
>>>> And those who came later. Paul doesn't seem to have had a hand in the
>>>> writing of the gospels, but the gospels appear to have been written
>>>> after Paul was doing his writing.
>>> There is an argument that it was Paul who actually invented
>>> Christianity.
>>
>> That suggestion is entirely dependent on your definition of "invent."
>> And at best it is only an "argument."
>>
>> Judaism has a similar problem with Moses inventing Abraham, and Ezra
>> inventing Moses.
>>
>> So who invented "Paul"? And who invented Ezra?
>>
>> TCross
>>
>>
>
>
> No, the only thing we are sure of is that Jesus didn't establish
> Christianity.

Considering the nonsense done in that poor guys name, I am sure he would
hastily deny anything to do with a religion that was not even named after
him.


Ralph

9/1/2009 8:35:00 PM

0

Terry Cross wrote:
> On Aug 31, 11:36 am, Ralph <mmman...@yahoo.com> wrote:
>> Terry Cross wrote:
>>> On Aug 31, 8:39 am, "Dan Listermann" <d...@listermann.com> wrote:
>>>> "Free Lunch" <lu...@nofreelunch.us> wrote in message
>>>> news:e1rn951h5r8371u8b9l7a4iq8u54ketpjs@4ax.com...
>>>>> On Mon, 31 Aug 2009 11:02:47 -0400, "Dan Listermann"
>>>>> <d...@listermann.com> wrote in alt.talk.creationism:
>>>>>> "Free Lunch" <lu...@nofreelunch.us> wrote in message
>>>>>> news:mpnn9594tk3j9hsectkoqp9lku2bur6h9f@4ax.com...
>>>>>>> On Mon, 31 Aug 2009 06:10:48 -0700 (PDT), Werewolfy
>>>>>>> <Werewol...@yahoo.co.uk> wrote in alt.talk.creationism:
>>>>>>>> On 27 Aug, 14:10, Steven Douglas <steven.doug...@rocketmail.com>
>>>>>>>> wrote:
>>>>>>>> "Jesus frequently spoke in parables. I don't take everything he said
>>>>>>>> literally, since it's obvious he often spoke figuratively."
>>>>>>>> I wonder why He did that? I mean, He arrives on earth to inform his
>>>>>>>> creations, to tell everyone about the ways of God..and yet he spoke in
>>>>>>>> riddles, rather than in understandable 'yes' or 'no' simple speech.
>>>>>>>> Like any politician, he never seems to answer any question, but simply
>>>>>>>> makes some seemingly profound statement around the outskirts of the
>>>>>>>> question...a statement that is frequently unintelligible.
>>>>>>>> Why? He came to deliver his message. Why choose to do so in such an
>>>>>>>> odd way. It reminds me of the digressions and subterfuge used by fake
>>>>>>>> Mediums as they pass obscure messages from beyond the grave to
>>>>>>>> relatives.
>>>>>>>> Why speak in parables..what was the point of that, considering He was
>>>>>>>> on Earth to spread 'the message'?
>>>>>>> Maybe because the Jesus of the gospels was just a sockpuppet of the
>>>>>>> people who were inventing the religion.
>>>>>> Paul?
>>>>> And those who came later. Paul doesn't seem to have had a hand in the
>>>>> writing of the gospels, but the gospels appear to have been written
>>>>> after Paul was doing his writing.
>>>> There is an argument that it was Paul who actually invented Christianity.
>>> That suggestion is entirely dependent on your definition of "invent."
>>> And at best it is only an "argument."
>>> Judaism has a similar problem with Moses inventing Abraham, and Ezra
>>> inventing Moses.
>>> So who invented "Paul"? And who invented Ezra?
>>> TCross
>> No, the only thing we are sure of is that Jesus didn't establish
>> Christianity.
>
> Given the formality and marvelous elasticity of the word "establish,"
> that is a no-brainer. Jesus, after all, never applied for
> ecclesiastical incorporation, and the IRS has no record of a credible
> 501(c)(3) application in Jesus' name.


Given your propensity for expanding on this elasticity instead of
answering a statement or question, I'm sure you will weasel out of this one.


>
> And I note Ralph says that is the *only* thing of which he is
> certain. For Ralph, the denial of Jesus is a certainty. ALL else in
> Ralph's life is in doubt.


You finally got something right, Cross and you didn't have to change the
meaning of any words. There is only one thing I am certain of in this
life an that is the god of the bible, in all its Christian forms, does
not exist. Let me type that more slowly for you Cross, your god doesn't
exist!




> You heard it from Ralph's own keyboard.
>
> TCross



You've got that right. By the way, it isn't really necessary for you to
sign your posts, we all know who you are.


Ralph

9/1/2009 8:40:00 PM

0

Dan Listermann wrote:
> "Ralph" <mmman_90@yahoo.com> wrote in message
> news:DMidne2rNbKqhQHXnZ2dnUVZ_gNi4p2d@giganews.com...
>> Terry Cross wrote:
>>> On Aug 31, 8:39 am, "Dan Listermann" <d...@listermann.com> wrote:
>>>> "Free Lunch" <lu...@nofreelunch.us> wrote in message
>>>>
>>>> news:e1rn951h5r8371u8b9l7a4iq8u54ketpjs@4ax.com...
>>>>
>>>>
>>>>
>>>>> On Mon, 31 Aug 2009 11:02:47 -0400, "Dan Listermann"
>>>>> <d...@listermann.com> wrote in alt.talk.creationism:
>>>>>> "Free Lunch" <lu...@nofreelunch.us> wrote in message
>>>>>> news:mpnn9594tk3j9hsectkoqp9lku2bur6h9f@4ax.com...
>>>>>>> On Mon, 31 Aug 2009 06:10:48 -0700 (PDT), Werewolfy
>>>>>>> <Werewol...@yahoo.co.uk> wrote in alt.talk.creationism:
>>>>>>>> On 27 Aug, 14:10, Steven Douglas <steven.doug...@rocketmail.com>
>>>>>>>> wrote:
>>>>>>>> "Jesus frequently spoke in parables. I don't take everything he said
>>>>>>>> literally, since it's obvious he often spoke figuratively."
>>>>>>>> I wonder why He did that? I mean, He arrives on earth to inform his
>>>>>>>> creations, to tell everyone about the ways of God..and yet he spoke
>>>>>>>> in
>>>>>>>> riddles, rather than in understandable 'yes' or 'no' simple speech.
>>>>>>>> Like any politician, he never seems to answer any question, but
>>>>>>>> simply
>>>>>>>> makes some seemingly profound statement around the outskirts of the
>>>>>>>> question...a statement that is frequently unintelligible.
>>>>>>>> Why? He came to deliver his message. Why choose to do so in such an
>>>>>>>> odd way. It reminds me of the digressions and subterfuge used by
>>>>>>>> fake
>>>>>>>> Mediums as they pass obscure messages from beyond the grave to
>>>>>>>> relatives.
>>>>>>>> Why speak in parables..what was the point of that, considering He
>>>>>>>> was
>>>>>>>> on Earth to spread 'the message'?
>>>>>>> Maybe because the Jesus of the gospels was just a sockpuppet of the
>>>>>>> people who were inventing the religion.
>>>>>> Paul?
>>>>> And those who came later. Paul doesn't seem to have had a hand in the
>>>>> writing of the gospels, but the gospels appear to have been written
>>>>> after Paul was doing his writing.
>>>> There is an argument that it was Paul who actually invented
>>>> Christianity.
>>> That suggestion is entirely dependent on your definition of "invent."
>>> And at best it is only an "argument."
>>>
>>> Judaism has a similar problem with Moses inventing Abraham, and Ezra
>>> inventing Moses.
>>>
>>> So who invented "Paul"? And who invented Ezra?
>>>
>>> TCross
>>>
>>>
>>
>> No, the only thing we are sure of is that Jesus didn't establish
>> Christianity.
>
> Considering the nonsense done in that poor guys name, I am sure he would
> hastily deny anything to do with a religion that was not even named after
> him.
>
>


I'm sure that if the person who was the historical Jesus came back today
he would not recognize the Christian church.


Dan Listermann

9/1/2009 8:47:00 PM

0


"Ralph" <mmman_90@yahoo.com> wrote in message
news:8tSdncVCu7k1GwDXnZ2dnUVZ_uUAAAAA@giganews.com...
> Dan Listermann wrote:
>> "Ralph" <mmman_90@yahoo.com> wrote in message
>> news:DMidne2rNbKqhQHXnZ2dnUVZ_gNi4p2d@giganews.com...
>>> Terry Cross wrote:
>>>> On Aug 31, 8:39 am, "Dan Listermann" <d...@listermann.com> wrote:
>>>>> "Free Lunch" <lu...@nofreelunch.us> wrote in message
>>>>>
>>>>> news:e1rn951h5r8371u8b9l7a4iq8u54ketpjs@4ax.com...
>>>>>
>>>>>
>>>>>
>>>>>> On Mon, 31 Aug 2009 11:02:47 -0400, "Dan Listermann"
>>>>>> <d...@listermann.com> wrote in alt.talk.creationism:
>>>>>>> "Free Lunch" <lu...@nofreelunch.us> wrote in message
>>>>>>> news:mpnn9594tk3j9hsectkoqp9lku2bur6h9f@4ax.com...
>>>>>>>> On Mon, 31 Aug 2009 06:10:48 -0700 (PDT), Werewolfy
>>>>>>>> <Werewol...@yahoo.co.uk> wrote in alt.talk.creationism:
>>>>>>>>> On 27 Aug, 14:10, Steven Douglas <steven.doug...@rocketmail.com>
>>>>>>>>> wrote:
>>>>>>>>> "Jesus frequently spoke in parables. I don't take everything he
>>>>>>>>> said
>>>>>>>>> literally, since it's obvious he often spoke figuratively."
>>>>>>>>> I wonder why He did that? I mean, He arrives on earth to inform
>>>>>>>>> his
>>>>>>>>> creations, to tell everyone about the ways of God..and yet he
>>>>>>>>> spoke in
>>>>>>>>> riddles, rather than in understandable 'yes' or 'no' simple
>>>>>>>>> speech.
>>>>>>>>> Like any politician, he never seems to answer any question, but
>>>>>>>>> simply
>>>>>>>>> makes some seemingly profound statement around the outskirts of
>>>>>>>>> the
>>>>>>>>> question...a statement that is frequently unintelligible.
>>>>>>>>> Why? He came to deliver his message. Why choose to do so in such
>>>>>>>>> an
>>>>>>>>> odd way. It reminds me of the digressions and subterfuge used by
>>>>>>>>> fake
>>>>>>>>> Mediums as they pass obscure messages from beyond the grave to
>>>>>>>>> relatives.
>>>>>>>>> Why speak in parables..what was the point of that, considering He
>>>>>>>>> was
>>>>>>>>> on Earth to spread 'the message'?
>>>>>>>> Maybe because the Jesus of the gospels was just a sockpuppet of the
>>>>>>>> people who were inventing the religion.
>>>>>>> Paul?
>>>>>> And those who came later. Paul doesn't seem to have had a hand in the
>>>>>> writing of the gospels, but the gospels appear to have been written
>>>>>> after Paul was doing his writing.
>>>>> There is an argument that it was Paul who actually invented
>>>>> Christianity.
>>>> That suggestion is entirely dependent on your definition of "invent."
>>>> And at best it is only an "argument."
>>>>
>>>> Judaism has a similar problem with Moses inventing Abraham, and Ezra
>>>> inventing Moses.
>>>>
>>>> So who invented "Paul"? And who invented Ezra?
>>>>
>>>> TCross
>>>>
>>>>
>>>
>>> No, the only thing we are sure of is that Jesus didn't establish
>>> Christianity.
>>
>> Considering the nonsense done in that poor guys name, I am sure he would
>> hastily deny anything to do with a religion that was not even named after
>> him.
>
>
> I'm sure that if the person who was the historical Jesus came back today
> he would not recognize the Christian church.
>

If he was half the nice guy he seemed to be, he would be mortified at the
nonsense done in his name. Christians should be ashamed of themselves and
find better things to do with their lives.