Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic
 
PerlMonks  

Re^4: Native newline encoding

by sauoq (Abbot)
on May 22, 2012 at 18:34 UTC ( [id://971846]=note: print w/replies, xml ) Need Help??


in reply to Re^3: Native newline encoding
in thread Native newline encoding

That's a bit obvious :)

Erm... what's the obvious part? That I don't do Windows or that it should be 0d0a? Or both?

He asked for the "native newline encoding of the OS"... It doesn't matter what writes it. Maybe it's because I don't do Windows but do have to deal the bastardized text files that come from Windows that the distinction is meaningless. I know I don't care whether it is Perl or the run time writing the characters. That they are there is what matters.

-sauoq
"My two cents aren't worth a dime.";

Replies are listed 'Best First'.
Re^5: Native newline encoding
by BrowserUk (Patriarch) on May 22, 2012 at 18:49 UTC
    He asked for the "native newline encoding of the OS"... It doesn't matter what writes it.

    Sorry mate! But it absolutely does matter.

    Which is why my post contains two questions which salva will get around to answering (or not) in his own time.


    With the rise and rise of 'Social' network sites: 'Computers are making people easier to use everyday'
    Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
    "Science is about questioning the status quo. Questioning authority".
    In the absence of evidence, opinion is indistinguishable from prejudice.

    The start of some sanity?

      But it absolutely does matter.

      No, it doesn't. To be clear (because we could confuse others with what we are saying matters and doesn't if we continue along this line):

      I am saying it doesn't matter what writes the characters, only that they are there.

      While you are saying it doesn't matter that they are there because of what writes them.

      And, you know, this is what I hate about Windows... the pervasive attitude that the OS is doing something for you that you can just ignore.

      Here's an assignment that would illustrate the difference... You are to write a textual file with X lines. Each line will have Y number of characters not including the newline. X and Y will be determined at runtime. Before writing the file, tell the user how big it will be on disk.

      Update: Make it portable, of course.

      -sauoq
      "My two cents aren't worth a dime.";
        I am saying it doesn't matter what writes the characters, only that they are there.

        Sorry, but you cannot possibly know that unless you have read salva's mind and thereby know what his purpose is!

        All the rest is supposition.


        With the rise and rise of 'Social' network sites: 'Computers are making people easier to use everyday'
        Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
        "Science is about questioning the status quo. Questioning authority".
        In the absence of evidence, opinion is indistinguishable from prejudice.

        The start of some sanity?

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://971846]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others studying the Monastery: (6)
As of 2024-04-23 11:53 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found