From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.ciao.gmane.io!not-for-mail From: Pip Cet Newsgroups: gmane.emacs.devel Subject: Re: 31395511: =?utf-8?Q?=22Don=E2=80=99t?= attempt to modify constant strings" Date: Thu, 04 Jun 2020 21:42:40 +0000 Message-ID: <878sh24ien.fsf@gmail.com> References: <871rmvn7ge.fsf@gmail.com> <87lfl36abx.fsf@gmail.com> <1abe5965-b48e-6dee-1516-c5c233f09d01@cs.ucla.edu> <87d06f5m2c.fsf@gmail.com> <87lfl3f5mj.fsf@tcd.ie> <87k10m4l5v.fsf@gmail.com> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="ciao.gmane.io:159.69.161.202"; logging-data="33986"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Cc: "Basil L. Contovounesios" , Paul Eggert , =?utf-8?B?Sm/Do28gVMOhdm9yYQ==?= , emacs-devel To: Stefan Monnier Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Thu Jun 04 23:43:41 2020 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jgxeH-0008kD-KG for ged-emacs-devel@m.gmane-mx.org; Thu, 04 Jun 2020 23:43:41 +0200 Original-Received: from localhost ([::1]:37038 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jgxeG-0005ov-KO for ged-emacs-devel@m.gmane-mx.org; Thu, 04 Jun 2020 17:43:40 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:34466) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jgxdS-0005Fa-9F for emacs-devel@gnu.org; Thu, 04 Jun 2020 17:42:50 -0400 Original-Received: from mail-ej1-x644.google.com ([2a00:1450:4864:20::644]:43158) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jgxdR-0006jZ-FD for emacs-devel@gnu.org; Thu, 04 Jun 2020 17:42:49 -0400 Original-Received: by mail-ej1-x644.google.com with SMTP id l12so3955559ejn.10 for ; Thu, 04 Jun 2020 14:42:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=8r82IICc0YHXc5or+8cnIx/OEYTk6lvmwdNinXF+F/c=; b=G+cPTZm8sjSgCuVNUvf6rXvEv9pFtgzwCx7hswCGb5SltBGJCJMAfRCGDtg0PBO0z8 lVQh3jWYkbYVlDLHphl6hHPliE1Wp9AYJ7v02QqTLjMqiv4hAjVKhFg3bx4f9wz1wdHS rUKOBHbBtGGjqjCI5pDBFueQMKqq+Bq/Zyi2PjDOCo2fowX6Wa+CHjoIk1wHdKQRccJr vh1G9pLCyr+JTAzeWLclzsDL9XLrdCBwxaWMEKipHlkZI4Vq28ByqLl4O+oNwgX2ijKF gJMIekaby6ED2Z7lrt8IADMIGCJ7g6ktvvJtuHWJHWveGHhIrrBE+SuFAC4MIs6iT5jW ZEug== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=8r82IICc0YHXc5or+8cnIx/OEYTk6lvmwdNinXF+F/c=; b=AELEgESUbQGodAa+g3JXaZBO4e8Z2rAMSEURfa3laAhj5vRzaVtRS+9fc56cFCCCCu YI8X3rNUcYJUP3t/edwMgZ6zboRWGwdUiBHk/G62UdvmQU9JWPnf0HcdobTl+4EIMkjI 1Qur99ByMjFPrBqDomg/lsGxTP2FVtHoCMH3jW2lkmiYAv2HndwslPMj+gYtUSg/gQMI hcWN+ZETgwNlcf36UOC9alOPjq3PLU+TDsxoKiwzME8XAqGIKvkvFI2n6RWVVuRDk2Tu oJAyEubWIha3LTwZUjhvPFa9ppE+doxBqQN4PNRmkth6S3glcgsWbdc9/ZcbUnBx6SH/ ox+w== X-Gm-Message-State: AOAM532RAym6rkdVxn8FZ1c6OzmpTOGtcuAhLhoNYgoLDCY+hqjyoQFQ JfR6oAV6dB04CvXlOjenUMvEygldDZ4= X-Google-Smtp-Source: ABdhPJzk9xMYXlsuMbymxRBeMeTjYWMBuC9h29c1g0VhDB/qvqLiGkZkThVaQ1q6LjbGwbc1J8vtLQ== X-Received: by 2002:a17:906:e0c:: with SMTP id l12mr5520361eji.435.1591306967791; Thu, 04 Jun 2020 14:42:47 -0700 (PDT) Original-Received: from chametz ([179.43.167.228]) by smtp.gmail.com with ESMTPSA id d6sm3464210edn.75.2020.06.04.14.42.44 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 04 Jun 2020 14:42:47 -0700 (PDT) In-Reply-To: (Stefan Monnier's message of "Thu, 04 Jun 2020 17:27:32 -0400") Received-SPF: pass client-ip=2a00:1450:4864:20::644; envelope-from=pipcet@gmail.com; helo=mail-ej1-x644.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001 autolearn=_AUTOLEARN X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.23 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-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:251866 Archived-At: Stefan Monnier writes: >> To be honest, I'd prefer a mutablep predicate, with a strong warning not >> to use it in the way that was suggested: >> >> (if (mutablep object) >> (do-something object) >> (do-something (copy object))) > > Aka (do-something (if (mutablep object) object (copy object))) All the more reason to avoid my bad-example code!