From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Philipp Stephani Newsgroups: gmane.emacs.devel Subject: Should `frame-title-format' protect the match data? Date: Fri, 18 May 2018 18:50:33 +0200 Message-ID: NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="000000000000c664f2056c7dc01d" X-Trace: blaine.gmane.org 1526662208 12482 195.159.176.226 (18 May 2018 16:50:08 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Fri, 18 May 2018 16:50:08 +0000 (UTC) To: Emacs developers Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Fri May 18 18:50:03 2018 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fJiZv-00038d-IH for ged-emacs-devel@m.gmane.org; Fri, 18 May 2018 18:50:03 +0200 Original-Received: from localhost ([::1]:39994 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fJic2-0002Ps-Lh for ged-emacs-devel@m.gmane.org; Fri, 18 May 2018 12:52:14 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:58245) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fJiad-0002Nj-7J for emacs-devel@gnu.org; Fri, 18 May 2018 12:50:48 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fJiac-0002KW-8E for emacs-devel@gnu.org; Fri, 18 May 2018 12:50:47 -0400 Original-Received: from mail-oi0-x231.google.com ([2607:f8b0:4003:c06::231]:37500) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1fJiac-0002KA-2A for emacs-devel@gnu.org; Fri, 18 May 2018 12:50:46 -0400 Original-Received: by mail-oi0-x231.google.com with SMTP id w123-v6so7670620oia.4 for ; Fri, 18 May 2018 09:50:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:from:date:message-id:subject:to; bh=CVUNyPQqmv6T5bBTvhl+5R5MgYR4KDPlmgglgztKX+4=; b=Upu8obbSEiybIk5Xd5YOGINXc/OHqf2cX2k2k0scaKMz5WtHnjeh/qBX6twmNpmmrJ GloZ7ZADkJoL3sPegM7thOYAqhTrDrL7mtHXN5fIt71zzu89nbXw84bJKpGnUsgSRrHr ZxmotahMn/FwZNmkPvRUt1H/hecjGrQvF4jDFd8YRaEUOUwOx8HRK6G//DPlSbpRBf/K rLRdQDKq4Dta4enrARX1PfSpnad6YMZib72iUfzmOjnX2OuhC4OjmOxHl17EPnsczHvX Cowwp9IMA+I8JNHWO/gLBEIEMiuxjz+/F+Gyc3K6cN4I2o7Gmxgf3Jvs5dMcx4hclY2e n3Kw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=CVUNyPQqmv6T5bBTvhl+5R5MgYR4KDPlmgglgztKX+4=; b=c1y8YPzQJKOONp0HAOqOajt72ysblOnj0t+22Y9Mk6o8me2vlrcW54oZp9ZqjvLOCP iaeyU976N8Vu27mXR7Ba0URj9dVkvA0EwIBE8HBciiyvmqDznm74ec0wgdIHmByPqBv6 jri/CQZcIn7gvbAt9siemN16hzA3EAiIcekPDztUsPqtMsleYr5SOfrIaS8+hqXo44q8 N+J4fllcMKIDkm+5P41nHMIntxtj59kSduESpLf2Wu+XfDs+MtokhwJcV7XkYSKqtTft tnyq4EvxsNwFlVDrgChZ5vbkcMTXStEbY0+Yy64jL2DwJKfCtqp9mopB+HC4xqnnskBT D08w== X-Gm-Message-State: ALKqPwdNSFpoJD06MIJ9i/LHwJGXfvIyq9SHLKVOGYwagbLN1VT/q1FH asNkqTKgl0cVUgGXSeRoRNyAOdH/kxrFvPznlqD9Ew== X-Google-Smtp-Source: AB8JxZrzYv9692rtilpRnPluo91niEeopV9qnFZE1fihIIcouJs87EqEPn/QxKNFrJKT+uMdWl6LhVK30pMHnYWVoYA= X-Received: by 2002:aca:ad13:: with SMTP id w19-v6mr6344179oie.137.1526662244490; Fri, 18 May 2018 09:50:44 -0700 (PDT) X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2607:f8b0:4003:c06::231 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.21 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" Xref: news.gmane.org gmane.emacs.devel:225408 Archived-At: --000000000000c664f2056c7dc01d Content-Type: text/plain; charset="UTF-8" Hi, consider emacs -Q -eval "(setq frame-title-format '(\"\" (:eval (string-match \".\" \"a\"))))" If you then run `query-replace' and actually try to replace something you get an error "args out of range" because the match data changed unexpectedly. This happens on master and the release branch, but not in Emacs 24.5. Should `frame-title-format' protect the match data, or does Emacs expect users to do that? Thanks, Philipp --000000000000c664f2056c7dc01d Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Hi,

consider

e= macs -Q -eval "(setq frame-title-format '(\"\" (:eval (s= tring-match \".\" \"a\"))))"

<= div>If you then run `query-replace' and actually try to replace somethi= ng you get an error "args out of range" because the match data ch= anged unexpectedly. This happens on master and the release branch, but not = in Emacs 24.5.
Should `frame-title-format' protect the match = data, or does Emacs expect users to do that?

Thank= s,
Philipp
--000000000000c664f2056c7dc01d--