From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Philipp Stephani Newsgroups: gmane.emacs.devel Subject: Re: Dynamic loading progress Date: Mon, 28 Sep 2015 15:35:45 +0000 Message-ID: References: <55DB7C3D.4090106@cs.ucla.edu> <55DE75FD.8020308@cs.ucla.edu> <55F5DD8C.70506@dancol.org> <55F62C16.4000105@dancol.org> <55F64F04.9030002@dancol.org> <55F6E43E.9030502@dancol.org> <55F70C4E.8030805@dancol.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: multipart/alternative; boundary=f46d04447df90e5d660520d074c1 X-Trace: ger.gmane.org 1443485467 17118 80.91.229.3 (29 Sep 2015 00:11:07 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 29 Sep 2015 00:11:07 +0000 (UTC) Cc: Tom Tromey , Stephen Leake , Daniel Colascione , Emacs development discussions , Paul Eggert To: =?UTF-8?Q?Aur=C3=A9lien_Aptel?= , Stefan Monnier Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Sep 29 02:11:06 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 1ZgiVd-0003it-TD for ged-emacs-devel@m.gmane.org; Tue, 29 Sep 2015 02:11:06 +0200 Original-Received: from localhost ([::1]:42877 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZgiVd-0004tG-B5 for ged-emacs-devel@m.gmane.org; Mon, 28 Sep 2015 20:11:05 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:39027) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZgaT8-0004Wc-DR for emacs-devel@gnu.org; Mon, 28 Sep 2015 11:35:59 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZgaT6-0007o4-Sz for emacs-devel@gnu.org; Mon, 28 Sep 2015 11:35:58 -0400 Original-Received: from mail-wi0-x22e.google.com ([2a00:1450:400c:c05::22e]:37083) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZgaT6-0007ns-Hw for emacs-devel@gnu.org; Mon, 28 Sep 2015 11:35:56 -0400 Original-Received: by wicfx3 with SMTP id fx3so106885081wic.0 for ; Mon, 28 Sep 2015 08:35:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc:content-type; bh=ENUNvCBwqTT1Xm7k5pwpliAq+ue1L2kGOn6QqxGOrdk=; b=hXZqpvos4HCbJnUM2uNPON+GOB0PGNIvbLi9YcGZW7d3s5tldgvU6VxQnjimRCAxgY CBVWmJ+BaRaop+1Fqyclo3frSnSTbK4FO09zz0cCnDbEz+3RO+aXlv1jIQwo+pkMrqR9 tN6YGBHa0B0JmOx2jWPacis0NdywNqRDdPyAmmEIDCVehQkvMkCH/SoBbMwFfZ4fLRKP krbrIkQwU/QxkHNRHUkCFoBzie6fcX6AOxiJYr5vC623XzSus/WfeU0QVbbUXuTjWYsg WNMEkC1JG5yMBlGjPPPzDZakQovBT0AIGi0NXORJh7vzK1ELI9zRpSAl7c1pb/qzLOD+ LDcA== X-Received: by 10.180.102.195 with SMTP id fq3mr19645157wib.7.1443454555936; Mon, 28 Sep 2015 08:35:55 -0700 (PDT) In-Reply-To: X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2a00:1450:400c:c05::22e 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:190445 Archived-At: --f46d04447df90e5d660520d074c1 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Aur=C3=A9lien Aptel schrieb am Do., 24. Se= p. 2015 um 14:45 Uhr: > Some updates. > > I haven't made any progress on errors. I was reading on > condition-case, setjmp/longjmp and how it's used for > signaling/throwing. I actually knew very little about it. I shouldnt > be the one writing this stuff I think... Anyway I was looking into how > I would set up a "catch-all" wrapping code so that we can implement a > funcall that always returns and I still haven't figured it out. I have implemented this in a private fork: https://github.com/phst/emacs-dynamic-module/commit/b14073ef8a522bdb90a8d7f= 0edc575edfd75da26 Note that code is only a suggestion how it could be implemented. It deviates from Daniel's design by using return parameters instead of TLS, but that's only a minor difference. The important part is the addition of protected_call_n to eval.c. > And realisticly if we > want this in emacs 25 it's the only way (I don't feel confident enough > to do that bit properly and I'm the only one working on this). I feel relatively strongly about this, so I'd work on implementing this if you'd like. > We can > always fix it afterwards or simply have a "safe" and an "unsafe" > version of funcall in the API. Going from the safe to the unsafe direction is easy if it's really required, but going the other direction is hard. I'd suggest to only implement the safe version for now and only add the unsafe version if there's some data that shows it's required. > I think changing the API in the early stage is fine and I don't worry > too much about binary API changes because it's only going to be used > with GPL plugins (i.e. modules can be fixed and recompiled, most of > the time). > > True, however once there's an API it's a good idea to keep it stable. I expect people to start writing modules relatively soon once the interface is available, so it's better to put a bit more effort into the interface. --f46d04447df90e5d660520d074c1 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable


Aur=C3= =A9lien Aptel <aurel= ien.aptel+emacs@gmail.com> schrieb am Do., 24. Sep. 2015 um 14:45=C2= =A0Uhr:
Some updates.

I haven't made any progress on errors. I was reading on
condition-case, setjmp/longjmp and how it's used for
signaling/throwing. I actually knew very little about it. I shouldnt
be the one writing this stuff I think... Anyway I was looking into how
I would set up a "catch-all" wrapping code so that we can impleme= nt a
funcall that always returns and I still haven't figured it out.

I have implemented this in a private fork:=C2=A0https://github.com/phst/emacs-dynamic-module/co= mmit/b14073ef8a522bdb90a8d7f0edc575edfd75da26
Note that code = is only a suggestion how it could be implemented. It deviates from Daniel&#= 39;s design by using return parameters instead of TLS, but that's only = a minor difference. The important part is the addition of protected_call_n = to eval.c.
=C2=A0
And realist= icly if we
want this in emacs 25 it's the only way (I don't feel confident eno= ugh
to do that bit properly and I'm the only one working on this).

I feel relatively strongly about this, so I'd = work on implementing this if you'd like.
=C2=A0
We can
always fix it afterwards or simply have a "safe" and an "uns= afe"
version of funcall in the API.

Going from t= he safe to the unsafe direction is easy if it's really required, but go= ing the other direction is hard. I'd suggest to only implement the safe= version for now and only add the unsafe version if there's some data t= hat shows it's required.
=C2=A0
I think changing the API in the early stage is fine and I don't = worry
too much about binary API changes because it's only going to be used with GPL plugins (i.e. modules can be fixed and recompiled, most of
the time).


True, however once there's an API = it's a good idea to keep it stable. I expect people to start writing mo= dules relatively soon once the interface is available, so it's better t= o put a bit more effort into the interface.=C2=A0
--f46d04447df90e5d660520d074c1--