From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: PJ Weisberg Newsgroups: gmane.emacs.devel Subject: Re: What does Emacs on w32 know that grep can't figure out? Date: Fri, 1 Oct 2010 08:11:11 -0700 Message-ID: References: <83y6aiqtbq.fsf@gnu.org> <83ocbeqfx2.fsf@gnu.org> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Trace: dough.gmane.org 1285946097 2018 80.91.229.12 (1 Oct 2010 15:14:57 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Fri, 1 Oct 2010 15:14:57 +0000 (UTC) Cc: lekktu@gmail.com, Lennart Borgman , emacs-devel@gnu.org To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Fri Oct 01 17:14:55 2010 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1P1hK1-0004Ni-5u for ged-emacs-devel@m.gmane.org; Fri, 01 Oct 2010 17:14:53 +0200 Original-Received: from localhost ([127.0.0.1]:54992 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1P1hK0-0001lQ-CA for ged-emacs-devel@m.gmane.org; Fri, 01 Oct 2010 11:14:52 -0400 Original-Received: from [140.186.70.92] (port=38308 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1P1hGb-0008HS-FR for emacs-devel@gnu.org; Fri, 01 Oct 2010 11:11:23 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1P1hGV-0008UX-Ar for emacs-devel@gnu.org; Fri, 01 Oct 2010 11:11:21 -0400 Original-Received: from smtpauth03.prod.mesa1.secureserver.net ([64.202.165.183]:37863) by eggs.gnu.org with smtp (Exim 4.71) (envelope-from ) id 1P1hGV-0008U6-1H for emacs-devel@gnu.org; Fri, 01 Oct 2010 11:11:15 -0400 Original-Received: (qmail 22341 invoked from network); 1 Oct 2010 15:11:13 -0000 Original-Received: from unknown (209.85.161.169) by smtpauth03.prod.mesa1.secureserver.net (64.202.165.183) with ESMTP; 01 Oct 2010 15:11:13 -0000 Original-Received: by gxk24 with SMTP id 24so1763443gxk.0 for ; Fri, 01 Oct 2010 08:11:12 -0700 (PDT) Original-Received: by 10.42.179.202 with SMTP id br10mr4388876icb.12.1285945872136; Fri, 01 Oct 2010 08:11:12 -0700 (PDT) Original-Received: by 10.42.5.138 with HTTP; Fri, 1 Oct 2010 08:11:11 -0700 (PDT) In-Reply-To: <83ocbeqfx2.fsf@gnu.org> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4-2.6 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:131165 Archived-At: On Fri, Oct 1, 2010 at 12:09 AM, Eli Zaretskii wrote: > Grep treats its input as a stream of bytes. =A0So it will not be able to > support any encoding where each character, including ASCII, takes 2 or > more bytes. =A0Unless you also encode the search string in the same > encoding, that is. In 5 minutes of testing I see that grep (GNU grep 2.6.3) doesn't handle null bytes in the pattern. (String ends at the first null, as c-strings are wont to do.) On Fri, Oct 1, 2010 at 5:02 AM, Eli Zaretskii wrote: >> From: Lennart Borgman >> Date: Fri, 1 Oct 2010 11:28:49 +0200 >> Cc: lekktu@gmail.com, emacs-devel@gnu.org >> >> > What's wrong with "M-x occur" and/or "M-x multi-occur"? >> >> They does not do what grep does. > > Like what? Recursively act on all files in a directory, for one. >> And as I said opening the files in a buffer will be bad because of perfo= rmance. > > What do you think Grep does? =A0Doesn't it open the files and read them? One line at a time. That'll make a difference for large files.