Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

paip.asd works around ANSI CL compatibility problems, doesn't document it and creates new problems #37

Open
lispm opened this issue Mar 17, 2018 · 0 comments

Comments

@lispm
Copy link

lispm commented Mar 17, 2018

paip.asd introduces a package PAIP which helps to deal with ANSI CL incompatibilities.

Unfortunately the file does not document why it is doing that and which issues it fixes how.

  • it is undefined to define a function for an external symbol of the package CL. This is the case for PAIP functions SYMBOL, DEBUG, IGNORE and OPTIMIZE. Thus the new package PAIP shadows these symbols. This then makes it impossible to use (declare (ignore ...)). One has to use (declare (cl:ignore ...). Similar for (declare (optimize ...)).

  • the shadowing definition of DEFCONSTANT has been provided because in ANSI CL it is only allowed to call DEFCONSTANT again with the same value. The same here means EQL. Thus (defconstant foo "foo") can't be called twice, while (defconstant bar 1) can. The paip code uses DEFCONSTANT with strings and lists - those are not necessarily EQL.

Unfortunately the paip.asd

creates new problems:

  • unfortunately the paip lisp source files have no package in the modeline and no in-package.
    Which can make editing a pain, since the editor might not know that all the code is in the PAIP package.

  • functions which use FIND-SYMBOL, INTERN and READ-FROM-STRING might need to be updated to look in the correct package. If there is no package parameter, they will look into whatever package is the runtime value of *PACKAGE*

  • the paip.asd file does not include modules for most of the source files - thus compiling/loading is done with a different mechanism

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant