From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Ted Zlatanov Newsgroups: gmane.emacs.devel Subject: Re: Dynamic loading progress Date: Sun, 03 May 2015 06:55:05 -0400 Organization: =?utf-8?B?0KLQtdC+0LTQvtGAINCX0LvQsNGC0LDQvdC+0LI=?= @ Cienfuegos Message-ID: <871tiy9bhy.fsf@lifelogs.com> References: <83h9unukbg.fsf@gnu.org> <54E0DEF8.7020901@dancol> <83egpruiyp.fsf@gnu.org> <54E0FF93.2000104@dancol.org> <833865vp4d.fsf@gnu.org> <54E2355A.90@87.69.4.28> <83vbj1u020.fsf@gnu.org> <54E24CA4.9020601@dancol.org> <83h9uk7ddb.fsf@gnu.org> <54E382A5.5030408@dancol.org> <54F789B2.6030105@dancol.org> <87egnel6ac.fsf@lifelogs.com> <87vbgpk1po.fsf@lifelogs.com> <85mw20gmeo.fsf@stephe-leake.org> Reply-To: emacs-devel@gnu.org NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1430650540 32029 80.91.229.3 (3 May 2015 10:55:40 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 3 May 2015 10:55:40 +0000 (UTC) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sun May 03 12:55:33 2015 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 1YorYa-0005rW-G4 for ged-emacs-devel@m.gmane.org; Sun, 03 May 2015 12:55:32 +0200 Original-Received: from localhost ([::1]:58898 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YorYZ-0007pt-Hl for ged-emacs-devel@m.gmane.org; Sun, 03 May 2015 06:55:31 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:35124) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YorYE-0007pn-TT for emacs-devel@gnu.org; Sun, 03 May 2015 06:55:11 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YorY9-0001gw-V3 for emacs-devel@gnu.org; Sun, 03 May 2015 06:55:10 -0400 Original-Received: from plane.gmane.org ([80.91.229.3]:59743) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YorY9-0001Zs-PE for emacs-devel@gnu.org; Sun, 03 May 2015 06:55:05 -0400 Original-Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1YorY6-0005T3-TH for emacs-devel@gnu.org; Sun, 03 May 2015 12:55:03 +0200 Original-Received: from c-98-229-61-72.hsd1.ma.comcast.net ([98.229.61.72]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sun, 03 May 2015 12:55:02 +0200 Original-Received: from tzz by c-98-229-61-72.hsd1.ma.comcast.net with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sun, 03 May 2015 12:55:02 +0200 X-Injected-Via-Gmane: http://gmane.org/ Mail-Followup-To: emacs-devel@gnu.org Original-Lines: 38 Original-X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: c-98-229-61-72.hsd1.ma.comcast.net X-Face: bd.DQ~'29fIs`T_%O%C\g%6jW)yi[zuz6; d4V0`@y-~$#3P_Ng{@m+e4o<4P'#(_GJQ%TT= D}[Ep*b!\e,fBZ'j_+#"Ps?s2!4H2-Y"sx" Mail-Copies-To: never User-Agent: Gnus/5.130012 (Ma Gnus v0.12) Emacs/25.0.50 (gnu/linux) Cancel-Lock: sha1:2i9UD7FAcJkdVMpSqOgyV1EEZA0= X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 80.91.229.3 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:186157 Archived-At: On Wed, 22 Apr 2015 11:25:51 -0500 Stephen Leake wrote: SL> Ted Zlatanov writes: >> I would go simple for now: always make a copy of the string using UTF-8 >> encoding in the args, assuming that the majority of C modules can deal >> with it, and we can stop worrying about string sharing and encoding for >> now (we can revisit them later). We should free the copy right after >> calling so the module doesn't have to free it. SL> I'm not clear who is freeing what here; the module API does need to SL> document that clearly. "We" was Emacs. So the module API will state "passed strings are a temporary copy that will be freed for you, so don't free() them, but if you do, it won't break anything." SL> We also need to document the GCPRO issues; ... SL> should the module do GCPRO around the funcall, or does the funcall SL> handle that? IMHO Emacs should manage memory, period. Any time modules are given that responsibility, it's an opportunity for bugs and a premature optimization. Perhaps we'll find it necessary later to give this responsibility to some modules, but let's not do it now. SL> Also, we need to do something about the doc strings for lisp objects SL> declared in modules. I don't think they need to be available before the SL> module is loaded; if a particular author wants that, they can define an SL> elisp wrapper with autoloads. SL> At a minimum, default doc string should be provided that gives a pointer SL> to the module source code. I have no strong opinion on this, but your suggestion sounds fine. Ted