From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Bastien Newsgroups: gmane.emacs.devel Subject: Re: Why (substring "abc" 0 4) does not return "abc" instead of an error? Date: Tue, 17 Jul 2012 00:48:04 +0200 Organization: GNU Message-ID: <87r4sbpbkr.fsf@altern.org> References: <87fw8smxag.fsf@gnu.org> <877gu4mv85.fsf@gnu.org> <871ukcmb47.fsf@gnu.org> <87hat7bqmh.fsf@gnu.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: dough.gmane.org 1342478861 16502 80.91.229.3 (16 Jul 2012 22:47:41 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Mon, 16 Jul 2012 22:47:41 +0000 (UTC) Cc: Juanma Barranquero , Stefan Monnier , emacs-devel@gnu.org To: Lennart Borgman Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Jul 17 00:47:40 2012 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Squ4o-0002Qp-66 for ged-emacs-devel@m.gmane.org; Tue, 17 Jul 2012 00:47:38 +0200 Original-Received: from localhost ([::1]:48151 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Squ4n-0005nO-IH for ged-emacs-devel@m.gmane.org; Mon, 16 Jul 2012 18:47:37 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:47682) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Squ4k-0005nJ-Jg for emacs-devel@gnu.org; Mon, 16 Jul 2012 18:47:35 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Squ4j-0002Ju-OT for emacs-devel@gnu.org; Mon, 16 Jul 2012 18:47:34 -0400 Original-Received: from mail-wi0-f171.google.com ([209.85.212.171]:47313) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Squ4j-0002Jo-Hu for emacs-devel@gnu.org; Mon, 16 Jul 2012 18:47:33 -0400 Original-Received: by wibhq4 with SMTP id hq4so2411511wib.12 for ; Mon, 16 Jul 2012 15:47:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=20120113; h=sender:from:to:cc:subject:in-reply-to:organization:references :user-agent:date:message-id:mime-version:content-type; bh=/PTOKiZ5FOVhbJsj6dfEt4ESbn4gwhkafK6c957YjKI=; b=wEdb00RGdNsp/x8Ika5zjGffH1wq6KWc87b319eqXMmzfaBzfJEl2bnL8pPzZAFSR/ yYXsK5l7INc/A6uZOqoZdOmioDbP99bz9nZCMfTJ32c1QtfK5z3VAp34TOo0L92wFHeI VQAsV2PzULhzKmnk3+y2FwUFCeAxBnmOvFuM1dxAc9DitV94xC1TVZw12Zx6tfMEaq1m ejgVek9DU62oZDBmr5W2WNR6/YF80vm87jg02915yCuBZaWQCRG51AJwfTEBWPh33sld KEdFu1T2ui4vUOinW+JUEuu5uFhDlbeaqA47v9IyboilWyFGmE5lWDQPaW5BzuRaTiv9 7yHg== Original-Received: by 10.216.133.90 with SMTP id p68mr64988wei.105.1342478852707; Mon, 16 Jul 2012 15:47:32 -0700 (PDT) Original-Received: from myhost.localdomain (mar75-2-81-56-68-112.fbx.proxad.net. [81.56.68.112]) by mx.google.com with ESMTPS id l5sm35102889wix.5.2012.07.16.15.47.31 (version=TLSv1/SSLv3 cipher=OTHER); Mon, 16 Jul 2012 15:47:32 -0700 (PDT) Original-Received: by myhost.localdomain (Postfix, from userid 1000) id 9AB2A8207; Tue, 17 Jul 2012 00:48:05 +0200 (CEST) In-Reply-To: (Lennart Borgman's message of "Tue, 17 Jul 2012 00:28:59 +0200") User-Agent: Gnus/5.130006 (Ma Gnus v0.6) Emacs/24.1.50 (gnu/linux) X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 209.85.212.171 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:151696 Archived-At: Lennart Borgman writes: > I really disagree. Would `string-head' suits your needs? I find out that most of the use-cases I have for my slackfull error-free substring version, is when the first index is 0. So this is the same than `string-head', really. `string-head' is also what Lars would need in the example he gave. -- Bastien