From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Mikael Djurfeldt Newsgroups: gmane.lisp.guile.devel,gmane.lisp.guile.user Subject: Re: Keywords in GOOPS methods v2 Date: Sun, 24 Nov 2024 18:54:28 +0100 Message-ID: References: Reply-To: mikael@djurfeldt.com Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="0000000000005544af0627ac4f52" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="2202"; mail-complaints-to="usenet@ciao.gmane.io" Cc: Jan Nieuwenhuizen , Tomas Volf <~@wolfsden.cz>, Maxime Devos , David Pirotte To: guile-user , guile-devel , =?UTF-8?Q?Ludovic_Court=C3=A8s?= , Andy Wingo Original-X-From: guile-devel-bounces+guile-devel=m.gmane-mx.org@gnu.org Sun Nov 24 18:55:03 2024 Return-path: Envelope-to: guile-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 1tFGp5-0000M1-DY for guile-devel@m.gmane-mx.org; Sun, 24 Nov 2024 18:55:03 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tFGop-00070o-Uv; Sun, 24 Nov 2024 12:54:47 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tFGom-00070D-NL; Sun, 24 Nov 2024 12:54:44 -0500 Original-Received: from mail-vs1-f44.google.com ([209.85.217.44]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1tFGok-0001pz-FH; Sun, 24 Nov 2024 12:54:43 -0500 Original-Received: by mail-vs1-f44.google.com with SMTP id ada2fe7eead31-4af1578d288so147981137.3; Sun, 24 Nov 2024 09:54:40 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1732470879; x=1733075679; h=cc:to:subject:message-id:date:from:reply-to:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=XTldhRevp5gxhuQsAVr4jaHQEOaKiQ8PUa/x+hIYoOY=; b=g+RYPfzMSI+CceZvoarctPIHWobaZ3EX3vz6e4LREfZMFL0kH+iIjLgFkK1qrtcL6G gmPeYs2paRoXKTU54uEdMc7H6duyjS6aOWNdxa7jWQws5X2Fs0YrsAy8dH24RI9eOE6M tMV+zueo8EkbMCgjXMpK+CBNFm7plph58SbyQtfMzfxNXrbO2O9DL/qpPfPnBUsbJeb8 N6zPE/rkCB7ljTqE6wNSLI7AlbsEBnaktkJvf3oMEqP6etBzEDPA3R22s26skl57ak8J bJohnC6TIzkfK8COGWoKF67x7JC5zqHylF9Ouv0NPxNShnfaS2ZTK0VI0dviOzbTgwGq X5Ng== X-Forwarded-Encrypted: i=1; AJvYcCV9KgNjL9KuPmFRUKMLsBryLhiK3Ebcsxl1CKpg46eBSWQsDVfOLG7w5GaKGbVyUI9GpCtyyA==@gnu.org, AJvYcCXotnpQfoXYK2NOUEpxlPBD/HeZDh8xkAfl5ZHlAkeJ1LrIqG1u+FvTb13UmW2LZGPpz41bI53wxUIN9Q==@gnu.org X-Gm-Message-State: AOJu0YwHIv4tv0kWzkKbhmdLjmvII9FsQocs4MpPNyzACMSMJnt3ogpv cn0kujywXekGZCWBBoH8o5Iuss8Md1UUjpCP9XD+KMQXPe21QeKWpKppoL2cq5ZVTzjTumpS5BZ AX91fc0Q1lKQvOpIpDHlWbJ/80W5GaA== X-Gm-Gg: ASbGncuoCWitMKigjOOXuVkg8m8OEwj2kSR8t37lCzhQSnieZsokJcm5WuG/l13w1kZ A9FukVi1xvVZFR6fdOD3k85xxY0b1sGtP X-Google-Smtp-Source: AGHT+IHibAScUx2YphTtxqHnICpGnhw0UtkGjDRE2u5giPBlq8m6PiCzlYUaOz+dUX2rNm2BUdnCOj40nCQzLpa9H+U= X-Received: by 2002:a05:6102:3f49:b0:4a8:ffbb:5531 with SMTP id ada2fe7eead31-4addcece627mr8886233137.25.1732470879107; Sun, 24 Nov 2024 09:54:39 -0800 (PST) In-Reply-To: Received-SPF: pass client-ip=209.85.217.44; envelope-from=mdjurfeldt@gmail.com; helo=mail-vs1-f44.google.com X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 5.0 requ) BAYES_00=-1.9, FREEMAIL_FORGED_FROMDOMAIN=0.001, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.001, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-0.93, RCVD_IN_VALIDITY_CERTIFIED_BLOCKED=0.001, RCVD_IN_VALIDITY_RPBL_BLOCKED=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: guile-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Developers list for Guile, the GNU extensibility library" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guile-devel-bounces+guile-devel=m.gmane-mx.org@gnu.org Original-Sender: guile-devel-bounces+guile-devel=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.lisp.guile.devel:22796 gmane.lisp.guile.user:19922 Archived-At: --0000000000005544af0627ac4f52 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Ah... I forgot to complete parse-keyword-formals, which is currently only rudimentary and doesn't compose the correct argument list for (next-method)= . There will be a version 3... On Sun, Nov 24, 2024 at 3:43=E2=80=AFPM Mikael Djurfeldt wrote: > Guile maintainers might want to consider if we should time this kind of > change in the API with a particular release. For my part, I think we coul= d > just add it. > > On Sun, Nov 24, 2024 at 3:40=E2=80=AFPM Mikael Djurfeldt > wrote: > >> This is my second attempt at introducing keyword aware methods in GOOPS. >> >> I was split but finally decided to go with keeping keyword non-aware >> define-method and method and introducing keyword aware new syntax method= * >> and define-method*. Arguments are: >> >> 1. It preserves simplicity in method and define-method such that other >> implementations (like guile-hoot) can choose to only define these (and >> possibly provide something like Mark's macro doe define-method*). >> 2. It aligns with lambda* and define*. >> 3. It is somewhat better at protecting backward compatibility. >> 4. It preserves the option to also in the internal implementation use >> something like Mark's macro once this gives equal performance. >> >> I've also committed these changes to >> >> https://github.com/mdjurfeldt/guile/tree/goops-keyword >> >> I'm going to start documenting this now and will then commit it to the >> Guile repo. >> >> Best regards, >> Mikael >> >> --0000000000005544af0627ac4f52 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Ah... I forgot to complete parse-keyword-formals, whi= ch is currently only rudimentary and doesn't compose the correct argume= nt list for (next-method).

There will be a ver= sion 3...

On Sun, Nov 24, 2024 at 3:43=E2=80=AFPM Mikael Djurfeldt= <mikael@djurfeldt.com> w= rote:
Guile maintainers might want to consider if we should time this ki= nd of change in the API with a particular release. For my part, I think we = could just add it.

On Sun, Nov 24, 2024 at 3:40=E2=80=AFPM Mikael Djurfe= ldt <mikael@dj= urfeldt.com> wrote:
This is my second attempt at introducing k= eyword aware methods in GOOPS.

I was split but fin= ally decided to go with keeping keyword non-aware define-method and method = and introducing keyword aware new syntax method* and define-method*. Argume= nts are:

1. It preserves simplicity in method = and define-method such that other implementations (like guile-hoot) can cho= ose to only define these (and possibly provide something like Mark's ma= cro doe define-method*).
2. It aligns with lambda* and define*.
3. It is somewhat better at protecting backward compatibility.
4. It preserves the option to also in the internal implementation us= e something like Mark's macro once this gives equal performance.
<= div>
I've also committed these changes to
--0000000000005544af0627ac4f52--