|
From: | Pietro Cerutti |
Subject: | Re: [patch] initial support for functors in csm |
Date: | Thu, 12 Oct 2023 09:59:45 +0000 |
User-agent: | NeoMutt/20231006-3-fdc654 |
On Oct 12 2023, 08:00 UTC, Pietro Cerutti <gahr@gahr.ch> wrote:
I haven't tackled (module NAME = FUNCTORNAME BODY ...) yet, but I can do that if there's consensus on this first part.
As it turns out, this was already trivially matched by the regular module definition form: ('module name _ . body).
I've added an alternative clause to make it explicit that we're matching the functor instantiation form, and to avoid recursively scanning the functor name.
The updated patch and set of example files is attached. The instantiations of the binop functor rely on this form.
-- Pietro Cerutti I have pledged to give 10% of income to effective charities and invite you to join me - https://givingwhatwecan.org
csm-functor-support-2.patch
Description: Text document
arith.mix.scm
Description: Text document
arith.num.scm
Description: Text document
arith.scm
Description: Text document
arith.str.scm
Description: Text document
binop.plus.scm
Description: Text document
binop.scm
Description: Text document
binop.times.scm
Description: Text document
main.scm
Description: Text document
num.scm
Description: Text document
str.scm
Description: Text document
[Prev in Thread] | Current Thread | [Next in Thread] |