Nick Maclaren wrote: > I have implemented both of those two models > on systems that are FAR more different than most people can imagine. > Both work, and neither causes confusion. The C/Unix/Python one does.
Now I'm not sure what *you* mean by the C/Unix/Python model. As far as newlines are concerned, the internal model is fine as far as I can see. > a mismatch between >>the world of Python strings which use "\n" and .NET >>library code expecting strings which use "\r\n". > > That's an I/O problem :-) If you define passing a string to/from any .NET function as I/O, I suppose that's true, but it's not what people normally mean by the term. > the REASON it causes trouble is the inconsistency > in the basic C/Unix/Python text I/O model. Let's consider just > \f, \r and \n, But we're not talking about \f or anything else here, only newlines. I've never heard anyone complain about getting confused over the handling of \f in Python. That may be because nobody uses \f for anything these days, but whatever the reason, it seems to be a non-issue. In any case, it still doesn't mean that you "don't get back what you wrote". If you write "\f\n" to a file using Python and read it back, you get "\f\n". If you write just "\f", you get back "\f". What the \f *means* is a separate issue. -- Greg Ewing, Computer Science Dept, +--------------------------------------+ University of Canterbury, | Carpe post meridiem! | Christchurch, New Zealand | (I'm not a morning person.) | [EMAIL PROTECTED] +--------------------------------------+ _______________________________________________ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com