From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.devel Subject: Re: Some dynamic module questions Date: Thu, 03 Dec 2020 10:13:47 -0500 Message-ID: References: <83zh33neyv.fsf@gnu.org> <83wny7nd2b.fsf@gnu.org> <83v9drncx7.fsf@gnu.org> <20201127135406.GI1558@odonien.localdomain> <83pn3yomzz.fsf@gnu.org> <20201127152114.GJ1558@odonien.localdomain> <83mtz2om79.fsf@gnu.org> <87o8jbz4z3.fsf@gnus.org> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="11863"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) Cc: Lars Ingebrigtsen , Emacs developers , Helmut Eller , Eli Zaretskii , Vasilij Schneidermann To: Philipp Stephani Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Thu Dec 03 16:18:18 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 1kkqN8-0002xg-Do for ged-emacs-devel@m.gmane-mx.org; Thu, 03 Dec 2020 16:18:18 +0100 Original-Received: from localhost ([::1]:60962 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kkqN7-0005xR-G1 for ged-emacs-devel@m.gmane-mx.org; Thu, 03 Dec 2020 10:18:17 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:49396) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kkqIs-0003I2-7q for emacs-devel@gnu.org; Thu, 03 Dec 2020 10:13:55 -0500 Original-Received: from mailscanner.iro.umontreal.ca ([132.204.25.50]:39834) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kkqIp-0005kn-NI; Thu, 03 Dec 2020 10:13:53 -0500 Original-Received: from pmg2.iro.umontreal.ca (localhost.localdomain [127.0.0.1]) by pmg2.iro.umontreal.ca (Proxmox) with ESMTP id F1F8880F2B; Thu, 3 Dec 2020 10:13:49 -0500 (EST) Original-Received: from mail01.iro.umontreal.ca (unknown [172.31.2.1]) by pmg2.iro.umontreal.ca (Proxmox) with ESMTP id 82BD380438; Thu, 3 Dec 2020 10:13:48 -0500 (EST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=iro.umontreal.ca; s=mail; t=1607008428; bh=KxyjLBhHz7tpgX5t7RrTIv6lXgh7LIlgjW1RFXjTxow=; h=From:To:Cc:Subject:References:Date:In-Reply-To:From; b=NL8U0O7BSM/lla/9PKUN2eY61ROYqBIoyC71wx3RE3jYlu9DyQe+8r7kGNHtAzQBY ylrU20oPNtMvFwHhrhk5FuKYMP3u+eQ05ngtTLnftNxwT6Z9/xWXWDXMMaoUrzTuxr jfWAYpXaxabEz4pfXhFBPdsEGONS7zDD8Z1eB69BS0pnFrBJHJJKjbsMd4QPexCUha 2tm9hqe05E99xFzA88oN9ZEyojy2YU9Rdw5xgcR0Xl3O6K1M/wzCenTjfvejaEUGqq +unDtZ9/tTddSlzhV0pltLI4qbSG0HTzBNDT23H2p4Rgzqvw60ZCZ7WfubuztIqF0W hyn2klPZ/85Gg== Original-Received: from alfajor (69-165-136-52.dsl.teksavvy.com [69.165.136.52]) by mail01.iro.umontreal.ca (Postfix) with ESMTPSA id 33B29120169; Thu, 3 Dec 2020 10:13:48 -0500 (EST) In-Reply-To: (Philipp Stephani's message of "Thu, 3 Dec 2020 12:49:10 +0100") Received-SPF: pass client-ip=132.204.25.50; envelope-from=monnier@iro.umontreal.ca; helo=mailscanner.iro.umontreal.ca X-Spam_score_int: -42 X-Spam_score: -4.3 X-Spam_bar: ---- X-Spam_report: (-4.3 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no 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:260223 Archived-At: > I agree that there should be a copy_unibyte_string_contents as well. An alternative would be to have a function like `copy_string_contents` which either returns bytes or a utf-8-encoded sequence of chars depending on whether the string was unibyte or not, and where it additionally returns an indication of which was the case. Stefan