[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Proper namespaces in Elisp
From: |
Andrea Corallo |
Subject: |
Re: Proper namespaces in Elisp |
Date: |
Fri, 08 May 2020 23:07:30 +0000 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/26.3 (gnu/linux) |
Vladimir Sedach <address@hidden> writes:
> There is no need to repeat the same mistakes. Andrea's proposal for
> namespacing over bindings/Scheme's approach avoids mangling the
> reader, does not cause problems for the printer, and does not make
> code resort to symbol-name hacks like LOOP does. Scheme's approach to
> namespacing has a lot of advantages over Common Lisp's.
>
> We can also avoid the "namespace multiple inheritance" problems of
> unintended re-definition and import conflicts if we combine João's
> approach of declaring prefixes with the ideas of package-local
> nicknames and namespaces over bindings.
>
> Here is how that might look:
>
> (declare-namespace jennys-awesome-string-library
> (use elisp29)
> (export foo))
>
> (declare-namespace jonnys-amazing-syntax-library
> (use elisp29)
> (export foo))
>
> (declare-namespace some-new-library
> (use elisp30)
> (import jennys-awesome-string-library st-)
> (import jonnys-amazing-syntax-library sy-))
Hi Vladimir,
This looks pretty similar as a concept to the raw prototype I've put
together and posted this evening:
https://lists.gnu.org/archive/html/emacs-devel/2020-05/msg01034.html
I do not have the prefix for importing but is something I wanted to add.
I'm learning also here that Scheme works on bindings too, good to be
ignorant!! :) Now I've very curios to see how different is from what I
came up with.
Andrea
--
address@hidden
- Re: Why :USE sucks in the Common Lisp package system, (continued)
- Re: Why :USE sucks in the Common Lisp package system, João Távora, 2020/05/09
- Re: Why :USE sucks in the Common Lisp package system, phoe, 2020/05/10
- Re: Why :USE sucks in the Common Lisp package system, Andrea Corallo, 2020/05/09
- Re: Why :USE sucks in the Common Lisp package system, Andreas Schwab, 2020/05/10
- Re: Why :USE sucks in the Common Lisp package system, Helmut Eller, 2020/05/10
- Re: Why :USE sucks in the Common Lisp package system, phoe, 2020/05/10
- Re: Proper namespaces in Elisp, Vladimir Sedach, 2020/05/09
- Re: Proper namespaces in Elisp,
Andrea Corallo <=
- Re: Proper namespaces in Elisp, Stefan Monnier, 2020/05/08
- Re: Proper namespaces in Elisp, Andrea Corallo, 2020/05/09
- Re: Proper namespaces in Elisp, Tuấn-Anh Nguyễn, 2020/05/09