From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: =?UTF-8?B?QW5kcmVhcyBSw7ZobGVy?= Newsgroups: gmane.emacs.help Subject: Re: string-match bug? Date: Wed, 09 Dec 2009 18:33:05 +0100 Message-ID: <4B1FDF51.1010002@easy-emacs.de> References: <4b1d1a48$0$278$14726298@news.sunsite.dk> <4b1d1e3d$0$276$14726298@news.sunsite.dk> <4B1D6773.3000509@easy-emacs.de> <4B1F5A38.1030703@easy-emacs.de> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Trace: ger.gmane.org 1260381081 891 80.91.229.12 (9 Dec 2009 17:51:21 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 9 Dec 2009 17:51:21 +0000 (UTC) Cc: help-gnu-emacs@gnu.org To: Juanma Barranquero Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Wed Dec 09 18:51:14 2009 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1NIQgn-00086V-Na for geh-help-gnu-emacs@m.gmane.org; Wed, 09 Dec 2009 18:51:02 +0100 Original-Received: from localhost ([127.0.0.1]:47000 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NIQgn-0003Zw-Lg for geh-help-gnu-emacs@m.gmane.org; Wed, 09 Dec 2009 12:51:01 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NIQPi-0004pD-G1 for help-gnu-emacs@gnu.org; Wed, 09 Dec 2009 12:33:22 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1NIQPd-0004n8-GW for help-gnu-emacs@gnu.org; Wed, 09 Dec 2009 12:33:21 -0500 Original-Received: from [199.232.76.173] (port=52930 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NIQPd-0004n2-CX for help-gnu-emacs@gnu.org; Wed, 09 Dec 2009 12:33:17 -0500 Original-Received: from moutng.kundenserver.de ([212.227.126.186]:59578) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1NIQPb-0004h8-SS for help-gnu-emacs@gnu.org; Wed, 09 Dec 2009 12:33:16 -0500 Original-Received: from [192.168.178.27] (p54BEB284.dip0.t-ipconnect.de [84.190.178.132]) by mrelayeu.kundenserver.de (node=mreu2) with ESMTP (Nemesis) id 0Lj72Q-1NncYx0u2o-00dDDo; Wed, 09 Dec 2009 18:33:13 +0100 User-Agent: Thunderbird 2.0.0.19 (X11/20081227) In-Reply-To: X-Provags-ID: V01U2FsdGVkX1+vCvBV2f9RPwyrw6MMdW5p/FH60AE2YSoJODc ZoDOvwhFWOSH4OnGu9U3EUGp1T7VybYFN9MHx0114btd3bpogY GyFVbl7bDdeT0BOOHUgteuk8UMgs54yXaiKFIAu0Q8= X-detected-operating-system: by monty-python.gnu.org: Genre and OS details not recognized. X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:70529 Archived-At: Juanma Barranquero wrote: > On Wed, Dec 9, 2009 at 09:05, Andreas Röhler > wrote: > >> Nonetheless, returning NIL at the second question looks like a more useful result - > > Why? > >> because taking incertitude. > > Which incertitude? Matching the empty regexp against any string is > always going to match. But simply by convention, isn't it? Aren't (string-match "" "a") and (string-match "" "") different cases in some perspective? The return value is censured being a position. Second case is plausible, there is an empty string at pos 0. First has no empty string at pos 0. Result is logically not plausible for me - even if I'm well able to live with... :) > > Juanma >