[Date Prev][Date Next][Thread Prev][Thread Next] [Search] [Date Index] [Thread Index]

Re: [MacPerl] When is \r really \n in MacPerl!?



At 7:44 PM -0600 2/9/98, Mark Manning/Muniz Eng. wrote:
>According to Mark F. Murphy:
>>
>> Ord \r: 10
>> Ord \n: 13
>>
>> In MacPerl 5.1.5r4.
>>
>> This is obviously a little backwards.
>
>I can see why this does this.  Or rather, I can see why \n
>returns the 13.  But shouldn't \r return 13 too?

I don't.

I can see why \n would print to the screen as a \r in MacPerl's window
(just as a terminal emulator does).

Just for the record, I converted over a script which auto determines the
line feed seperator for a data file.  It broke under MacPerl because of
these escaped chars being reversed.  So now I must use \x0D\x0A instead if
I want to program around MacPerl's difference in the Perl community.

mark

---------------------------------------------------------------------------
 Mark F. Murphy, Director Software Development   <mailto:markm@tyrell.com>
 Tyrell Software Corp                            <http://www.tyrell.com>
 PowerPerl(tm), Add Power To Your Webpage!       <http://www.powerperl.com>
---------------------------------------------------------------------------
Member of Families Against Internet Censorship: rainbow.rmi.net/~fagin/faic



***** Want to unsubscribe from this list?
***** Send mail with body "unsubscribe" to mac-perl-request@iis.ee.ethz.ch