On Sun, Feb 23, 2014 at 11:27 AM, Robert Goldman rpgoldman@sift.net wrote:
There's an error while reporting a warning (warning about your system having a bad version string). I suggest you add this method in system.lisp after defclass system: (defmethod builtin-system-p ((x null)) nil) Does it help?
Robert, do you want me to commit that?
I'd like to understand this patch better before we push it.
Why is it that having a method on NIL is right? Doesn't this just mask a bug where we are incorrectly treating NIL as if it's a system designator?
What's the cause for trying to ask if NIL is a built in system? Presumably some system lookup returned NIL, right? If so, why wasn't that trapped as an error?
In this case it's not so much a system designator than something returned by (find-system name nil) in a case where it's acceptable. The test that matters is in parse-defsystem.lisp function normalize-version: (unless (builtin-system-p (find-component parent component)) which for backward compatibility (probably with old SBCL), declines to warn about builtin systems that have badly formed version strings. But in this case, the system doesn't exist, so find-system returns nil, and builtin-system-p errors out instead of returning nil.
The warning message should NOT error out when the system doesn't exist, and either you should put that unless under an (if-let (dep (find-component parent component)) ...) or you should make builtin-system-p accept nil as input (nil does not designate a builtin-system).
Now, from Mark Evenson's explanation of how abcl-asdf is abusing the version string, it seems that indeed, abcl should not be doing that — at least, not unless and until we adopt some extensible version-compatibility protocol, as has been discussed before, though without a fully worked out proposal. Note that the strict "semantic versioning" requirement of ASDF versions already existed in ASDF1, but wasn't enforced, except backhandedly by hand/or ASDF3 saving version-satisfies (and thus :version dependency-def) silently give non-meaningful answers. ASDF2 started issuing warnings instead, which is the right thing to do. Eventually, these warnings could be turned into errors, after cleaning up quicklisp.
Mark: yes, abcl-asdf better avoid that route for now, unless you want to first propose a patch to asdf. Please use a different slot maven-version or some such.
—♯ƒ • François-René ÐVB Rideau •Reflection&Cybernethics• http://fare.tunes.org Q. Why does "philosophy of consciousness/nature of reality" seem to interest you so much? A. Take away consciousness and reality and there's not much left. — Greg Egan, interview in Eidolon 15