[29314] in Perl-Users-Digest
Perl-Users Digest, Issue: 558 Volume: 11
daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Fri Jun 22 21:10:25 2007
Date: Fri, 22 Jun 2007 18:09:12 -0700 (PDT)
From: Perl-Users Digest <Perl-Users-Request@ruby.OCE.ORST.EDU>
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)
Perl-Users Digest Fri, 22 Jun 2007 Volume: 11 Number: 558
Today's topics:
Re: Assigning another filehandle to STDOUT, using binmo <paduille.4061.mumia.w+nospam@earthlink.net>
Re: Assigning another filehandle to STDOUT, using binmo <dummy@example.com>
Re: Assigning another filehandle to STDOUT, using binmo <paduille.4061.mumia.w+nospam@earthlink.net>
Re: FAQ 1.6 What is perl6? <tadmc@seesig.invalid>
People who reply to spammers [was: Re: I need some clea <steve@REMOVE.THIS.cybersource.com.au>
Re: Portable general timestamp format, not 2038-limited <roger.miller@nova-sol.com>
Re: Portable general timestamp format, not 2038-limited <http://phr.cx@NOSPAM.invalid>
Re: The Modernization of Emacs <twisted0n3@gmail.com>
Re: The Modernization of Emacs <twisted0n3@gmail.com>
Re: The Modernization of Emacs nebulous99@gmail.com
Re: The Modernization of Emacs <lew@lewscanon.nospam>
Re: The Modernization of Emacs <mkb@incubus.de>
Digest Administrivia (Last modified: 6 Apr 01) (Perl-Users-Digest Admin)
----------------------------------------------------------------------
Date: Fri, 22 Jun 2007 22:55:01 GMT
From: "Mumia W." <paduille.4061.mumia.w+nospam@earthlink.net>
Subject: Re: Assigning another filehandle to STDOUT, using binmode.
Message-Id: <9rYei.138$rR.51@newsread2.news.pas.earthlink.net>
On 06/22/2007 01:18 PM, Adam Funk wrote:
> On 2007-06-21, Dr.Ruud wrote:
>
>> Adam Funk schreef:
>>
>>> Is using binmode the most correct way to suppress those annoying "Wide
>>> character" warnings?
>> What is annoying about them? The just mean that you need to fix your
>> program.
>
> OK, let my try a different set of questions: is using binmode the
> correct way to fix the error that causes those warnings?
>
Yes.
>
> As I said, I'm running the program in a UTF-8 environment but getting
> thousands (I think) of identical warnings about "Wide characters"
> which actually refer to correct UTF-8 characters that Perl has read
> from input data files without a hiccup.
>
> Why is it unreasonable that I find this annoying?
> or
> What am I doing that constitutes an error?
You probably are assuming that open() configures your filehandles with
binmode() for you. This isn't true.
If you open a file, and it needs a special encoding, you need to call
binmode(). If you close and re-open STDOUT, you need to call binmode()
on it (if it needs encoding). If you close and re-open STDOUT when it's
aliased as OUTPUT, you still need to set up the encoding.
When you need an encoding, it's your responsibility to use binmode() to
set it on each file handle. The only exception I'm aware of is when the
"encoding" module is used. But that only sets up STDIN and STDOUT, and
it only sets them once. Even if the encoding pragma is used, if STDOUT
is closed and re-opened, binmode() must be called on it again.
------------------------------
Date: Fri, 22 Jun 2007 23:18:44 GMT
From: "John W. Krahn" <dummy@example.com>
Subject: Re: Assigning another filehandle to STDOUT, using binmode.
Message-Id: <oNYei.1157$qC1.796@edtnps89>
Mumia W. wrote:
> On 06/22/2007 01:18 PM, Adam Funk wrote:
>> On 2007-06-21, Dr.Ruud wrote:
>>
>>> Adam Funk schreef:
>>>
>>>> Is using binmode the most correct way to suppress those annoying "Wide
>>>> character" warnings?
>>> What is annoying about them? The just mean that you need to fix your
>>> program.
>>
>> OK, let my try a different set of questions: is using binmode the
>> correct way to fix the error that causes those warnings?
>
> Yes.
>
>> As I said, I'm running the program in a UTF-8 environment but getting
>> thousands (I think) of identical warnings about "Wide characters"
>> which actually refer to correct UTF-8 characters that Perl has read
>> from input data files without a hiccup.
>>
>> Why is it unreasonable that I find this annoying?
>> or
>> What am I doing that constitutes an error?
>
> You probably are assuming that open() configures your filehandles with
> binmode() for you. This isn't true.
You mean like:
open FH, '<:raw', 'filename';
??
John
--
Perl isn't a toolbox, but a small machine shop where you
can special-order certain sorts of tools at low cost and
in short order. -- Larry Wall
------------------------------
Date: Sat, 23 Jun 2007 00:59:55 GMT
From: "Mumia W." <paduille.4061.mumia.w+nospam@earthlink.net>
Subject: Re: Assigning another filehandle to STDOUT, using binmode.
Message-Id: <fg_ei.71$tj6.19@newsread4.news.pas.earthlink.net>
On 06/22/2007 06:18 PM, John W. Krahn wrote:
> Mumia W. wrote:
>> [...]
>> You probably are assuming that open() configures your filehandles with
>> binmode() for you. This isn't true.
>
> You mean like:
>
> open FH, '<:raw', 'filename';
>
> ??
>
>
> John
Oh yeah.
;-)
------------------------------
Date: Sat, 23 Jun 2007 00:30:21 GMT
From: Tad McClellan <tadmc@seesig.invalid>
Subject: Re: FAQ 1.6 What is perl6?
Message-Id: <slrnf7opr3.469.tadmc@tadmc30.sbcglobal.net>
Clenna Lumina <savagebeaste@yahoo.com> wrote:
> I have
> seen soem regualars reepatedly tell people not to reinvent whats already
> good and working and accepted.
Like acceptable spelling.
If some famous Perl guy would of jsut implemented a spell-correcting 'bot,
then things would of been a lot better around here...
--
Tad McClellan
email: perl -le "print scalar reverse qq/moc.noitatibaher\100cmdat/"
------------------------------
Date: Sat, 23 Jun 2007 11:07:04 +1000
From: Steven D'Aprano <steve@REMOVE.THIS.cybersource.com.au>
Subject: People who reply to spammers [was: Re: I need some cleanings tips and advice.]
Message-Id: <pan.2007.06.23.01.07.03.710059@REMOVE.THIS.cybersource.com.au>
On Fri, 22 Jun 2007 16:11:58 +0000, Colin B. replied to a spammer with:
> Let's see if I get this right.
>
> You create a website for a subject that you know nothing about. Then you
> try to solicit content in a bunch of programming language newsgroups.
>
> Wow, that's pretty pathetic, even for a google-groups poster!
>
> Begone with you.
You know, my ISP did a pretty good job of recognizing the original post as
spam, and dropped it, so I never even saw it until your post came along.
So I wonder, who is more pathetic -- the spammer, who at least is hoping
to make money from his rudeness, or idiots who try to reason with spammers
AND include the spam in their reply?
Thanks a lot Colin, I really appreciate you finding a way to bypass the
spam filtering. Not.
(You know, if I were a spammer, I would disguise my spam as an indignant
response to spam, thus guaranteeing a vastly greater audience.)
Colin, if that doesn't convince you to STOP ENGAGING SPAMMERS IN
DISCUSSION, no matter how witty you think your reply is, let me
point out that by rudely including the text of the spam in your
post, you are associating your name and email address with spam. That
might not be such a good thing to do as more and more people use Bayesian
filtering.
Follow-ups set to comp.lang.python.
--
Steven.
------------------------------
Date: Fri, 22 Jun 2007 15:49:20 -0700
From: Roger Miller <roger.miller@nova-sol.com>
Subject: Re: Portable general timestamp format, not 2038-limited
Message-Id: <1182552560.194980.297550@z28g2000prd.googlegroups.com>
On Jun 22, 10:33 am, James Harris <james.harri...@googlemail.com>
wrote:
> I have a requirement to store timestamps in a database. Simple enough
> you might think but finding a suitably general format is not easy.
> ...
> Any thoughts on a better way to do this? (Please reply-all. Thanks).
>
> --
> James
My rule of thumb in situations like this is "When in doubt store it as
text". The one format I am pretty sure we will still be able to deal
with in 2039.
- Roger
------------------------------
Date: 22 Jun 2007 16:51:32 -0700
From: Paul Rubin <http://phr.cx@NOSPAM.invalid>
Subject: Re: Portable general timestamp format, not 2038-limited
Message-Id: <7xhcozeeez.fsf@ruckus.brouhaha.com>
James Harris <james.harris.1@googlemail.com> writes:
> I have a requirement to store timestamps in a database. Simple enough
> you might think but finding a suitably general format is not easy. The
> specifics are
>
> 1) subsecond resolution - milliseconds or, preferably, more detailed
> ...
There are subtle issues that have been messed up many times. See:
http://cr.yp.to/time.html
particularly the TAI stuff for some info.
------------------------------
Date: Fri, 22 Jun 2007 22:12:34 -0000
From: Twisted <twisted0n3@gmail.com>
Subject: Re: The Modernization of Emacs
Message-Id: <1182550354.781164.238200@z28g2000prd.googlegroups.com>
On Jun 21, 11:11 am, Lew <l...@lewscanon.nospam> wrote:
> Joel J. Adamson wrote:
> > My point is that I'm the sort of person that has a mind set up for
> > Emacs. I had none of the difficulties that someone else might have,
> > who's used to other kinds of software.
>
> > However, I'll also point out that my wife has used Emacs a couple
> > times, and she's never done more than point and click with a computer,
> > and she's had no frustration whatsoever.
>
> A new user of two hours' experience. A father of a six-year old whose child
> hums along happily with emacs. A computer widow who "had no frustration
> whatsoever" with it.
>
> To the claim that "emacs is too hard for the beginner" we have a mounting pile
> of steaming evidence that refutes.
It's a steaming pile of something, of that I am sure, but I don't
think "evidence" is the word I'd use to describe it. The word I'm
thinking of IS eight letters long, but it starts with "b" instead of
"e"...
I find these anecdotes liberally sprinkled into this thread frankly
unbelievable. Either they are not using the same software I understand
"emacs" to refer to, or someone somewhere is simply lying. Or maybe
there's a bunch of prodigies around and they all picked now to pipe
up? We can't design software or any other tool to cater exclusively to
a handful of Mozarts, though, unless there's no reason to believe
anyone outside that small and exclusive club will ever have a use for
it.
> To the claim that the help is too hard to use comes the evidence that three
> simple keystroke patterns are all one needs to know, and anecdotal evidence of
> the help system's utility.
Utility is nothing without usability. In particular, no matter how
much useful content the help might have, the fact that when the
document window has the focus the help is always open to the section
on switching windows rather puts a crimp in the actual usability of
that information. The only times you can use it and the only times you
can read it are non-overlapping sets.
> Some will refuse to face the truth. To the open-minded, let the facts speak
> for themselves.
A few anecdotes prove nothing. A first year statistics 101 dropout
knows that much.
------------------------------
Date: Fri, 22 Jun 2007 22:38:04 -0000
From: Twisted <twisted0n3@gmail.com>
Subject: Re: The Modernization of Emacs
Message-Id: <1182551884.239660.209700@x35g2000prf.googlegroups.com>
On Jun 22, 11:52 am, Bjorn Borud <borud-n...@borud.no> wrote:
> [Martin Gregorie <mar...@see.sig.for.address>]
> |
> | Yep, and the same people think a command line is to be avoided at all
> | costs. "I mean, its so /last century/ and you can't do anything useful
> | with it anyway".
I think a command line can be useful as a way to directly talk to
something's brain. More GUI apps should have a command processor you
can access to do something arcane once in a while. The other thing a
command processor is good for is providing automation support.
Windows is definitely weak on allowing things like editors to be
embedded and used as components by other applications. OLE makes it
theoretically possible to e.g. use Winword in an IDE but who'd want
to? It also doesn't provide a system-wide way to select particular
components to do particular jobs -- the closest thing would be
splitting comctl32.dll into separate dlls for each common task or
dialog and allowing third-party drop-in replacements to be found in a
user-specific directory that override the defaults. That sort of
modularity and choice is alien to MS thought patterns however.
Combining the flexibility of componentry in Unix with the graphical
power of Windows might lead to something awesome ... which makes KDE
and Gnome things to keep eyes on in the future.
> I have observed similar opinions in other non-computer-freaks. people
> who see the computer only as a tool and are only interested in getting
> the job done. they have a surprising preference for Linux.
But not emacs, I'll bet. I think emacs appeals to people who like
dealing with the mechanics of emacs or fiddling with and extending the
darn thing. But most people just want to get the job done, and the
editor or other tools they use have to get out of the way and simply
let them work. If their attention keeps being dragged forcible from
THE JOB to THE TOOL and how to make this cantankerous thing do *this*?
then there is a problem. If I sit down at a windows text editor (or
even kwrite or similar) I can just focus on the job. Faced with emacs
or most other text-mode editors (but not MS-DOS Edit, interestingly)
the editor keeps intruding on my focus. Oops.
Elsewhere, you mentioned 3 second attention spans -- I think you'll
find people are much more willing to spend 3 hours of attention on
their task than 3 seconds on your favorite tool. When the tool
intrudes into the user's attention (either by misbehaving, e.g.
crashing, or by confounding the user as to how to do what they want to
do next), then a problem is evident.
------------------------------
Date: Fri, 22 Jun 2007 22:44:14 -0000
From: nebulous99@gmail.com
Subject: Re: The Modernization of Emacs
Message-Id: <1182552254.233679.180790@o11g2000prd.googlegroups.com>
On Jun 21, 10:48 am, Lew <l...@lewscanon.nospam> wrote:
> Bjorn Borud <borud-n...@borud.no> writes:
> >> so if the context was system administration, I'd vote for vi as
> >> well. if the context was programming I'd vote Emacs.
> David Kastrup wrote:
> > You know you can use something like
> > C-x C-f /su::/etc/fstab RET
> > (or /sudo::/etc/fstab) in order to edit files as root in a normal
> > Emacs session?
>
> I've been using emacs for something like twenty years and never knew that before.
>
> I like the built-in therapist in emacs.
I think both of Lew's sentences here speak volumes.
One about the difficulty even supposed expert users can have with
tasks and finding things out from the help system. (I take it unix has
also still not caught up to the windows world in the concept of a "tip
of the day"?)
And both of them, though especially the latter, regarding what a
feeping creature emacs is. I don't suppose there's also a kitchen sink
in there somewhere? Or is that just nethack?
PS you'll have to stop posting such a high volume here. I'm getting BS
from Google Groups about posting limits being exceeded again.
Apparently they've lowered it still further, from 25 in a 24 hour
period to 12 or so in a 24 hour period. Fuckers.
------------------------------
Date: Fri, 22 Jun 2007 19:17:36 -0400
From: Lew <lew@lewscanon.nospam>
Subject: Re: The Modernization of Emacs
Message-Id: <J4mdndKpSpYNxeHbnZ2dnUVZ_vninZ2d@comcast.com>
Twisted wrote:
> I find these anecdotes liberally sprinkled into this thread frankly
> unbelievable. Either they are not using the same software I understand
> "emacs" to refer to, or someone somewhere is simply lying.
So if someone provides evidence with which you disagree, you accuse them of lying.
There's no opportunity for reasoned discourse in the face of such tactics. Or
room for new information to combat one's prejudices.
--
Lew
------------------------------
Date: Sat, 23 Jun 2007 02:13:36 +0200
From: Matthias Buelow <mkb@incubus.de>
Subject: Re: The Modernization of Emacs
Message-Id: <5e36tcF3606a0U1@mid.dfncis.de>
Twisted wrote:
> I find these anecdotes liberally sprinkled into this thread frankly
> unbelievable.
If you'd spent as much time learning the software as you're ranting
about it, you could actually use it _and_ would get the additional
benefit of having avoided making a fool of yourself on Usenet. Of course
that would have been too easy, wouldn't it?
------------------------------
Date: 6 Apr 2001 21:33:47 GMT (Last modified)
From: Perl-Users-Request@ruby.oce.orst.edu (Perl-Users-Digest Admin)
Subject: Digest Administrivia (Last modified: 6 Apr 01)
Message-Id: <null>
Administrivia:
#The Perl-Users Digest is a retransmission of the USENET newsgroup
#comp.lang.perl.misc. For subscription or unsubscription requests, send
#the single line:
#
# subscribe perl-users
#or:
# unsubscribe perl-users
#
#to almanac@ruby.oce.orst.edu.
NOTE: due to the current flood of worm email banging on ruby, the smtp
server on ruby has been shut off until further notice.
To submit articles to comp.lang.perl.announce, send your article to
clpa@perl.com.
#To request back copies (available for a week or so), send your request
#to almanac@ruby.oce.orst.edu with the command "send perl-users x.y",
#where x is the volume number and y is the issue number.
#For other requests pertaining to the digest, send mail to
#perl-users-request@ruby.oce.orst.edu. Do not waste your time or mine
#sending perl questions to the -request address, I don't have time to
#answer them even if I did know the answer.
------------------------------
End of Perl-Users Digest V11 Issue 558
**************************************