[prev in list] [next in list] [prev in thread] [next in thread] 

List:       ruby-talk
Subject:    Re: why won't ruby chomp for me?
From:       Steven Jenkins <steven.jenkins () ieee ! org>
Date:       2004-01-29 15:47:49
Message-ID: 40192B1D.7080504 () ieee ! org
[Download RAW message or body]

ts wrote:
>  Probably the good question is : what is a line ? do the "line" separator
>  belong to the line or not ?

I suppose any language can define it any way. But it seems clear that 
much of the Ruby library is modeled after C and Unix (which are defined 
by international standards). In ISO C, the newline is removed from the 
string returned by gets().

On the other hand, C doesn't let you redefine the input line separator. 
Making one language comply with another language's specification is tricky.

Steve


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic