freenode/#lisp - IRC Chatlog
Search
18:49:01
phoe
Fare: what is the way of extending ASDF with a new operation? Is it possible to have things like a forward-referenced operation in a DEFSYSTEM form?
18:51:56
phoe
if I wanted to, say, :perform (ci-test-op (o c) (...)) in an ASD file, is it possible to have ASDF notice that the operation CI-TEST-OP is not defined yet, and therefore create a stand-in in form of a forward referenced class of some sort?
18:52:34
phoe
It obviously makes it impossible to invoke the CI-TEST-OP operation; but the benefit is that such ASDF forms will compile.
18:56:52
PuercoPope
phoe: instead of a new OP I think it would be better for the runners of test frameworks to support a mode where they terminate the process with the proper exit code instead. It is the same operation after all.
18:58:25
phoe
There's a lot said about ASDF backwards compatibility, but I haven't yet seen much about the other direction
20:20:40
Fare
phoe: you can refer to a class by symbol in :in-order-to specifications and component-depends-on methods, if that's what you mean.
20:22:48
phoe
Fare: let's suppose that ASDF 3.6 defines a new standard operation, ASDF:CI-TEST-OP. How can I add information about this new operation to a DEFSYSTEM form that will also not break it for current versions of ASDF?
20:27:00
phoe
we could, in theory, define an ASDF system that defines CI-TEST-OP if it is not already defined, and use it in DEFSYSTEM-DEPENDS-ON
20:28:20
jackdaniel
if asdf had its own reader (because it claims that asd files *are not* lisp source files), you could have used your-system:foobar from your yet-to-be-defined system
20:32:55
Fare
you don't need #+asdf3.6 in your :in-order-to as long as the present actions don't depend on future actions.
20:33:28
phoe
Fare: it's not an issue of missing fields, it's an issue of referencing operations before they are defined
20:33:51
Fare
asd files ARE lisp source files, to be read in a specific context different from the context used for regular lisp files.
20:33:53
phoe
the only field I need is :perform but :perform does not accept symbols that do not (yet) name concrete operation classes
20:35:09
jackdaniel
I'd expect that if my system "foo" defsystem-depends-on bar, which defines operation bar:xyz, then I could use bar:xyz operation in foo
20:36:17
Fare
the only issue might be if you want the package for your operation class to be defined as part of this defsystem-depends-on.
20:37:10
Fare
Then a small patch to ASDF might allow you to use strings as symbol designators in :perform specifications as well as in other places in defsystem.
20:39:11
Fare
It's possible that for now you might have to (load-system "bar") as a prelude to the (defsystem ... :perform (bar:bar-op ...))
20:40:13
Fare
I'm sure that a patch to ASDF to support the latter would be accepted... just a bit too late for your current project.
20:40:58
Fare
but ASDF certainly teaches patience... I've had a branch waiting for approval for 5 years.
21:15:49
ralt
I don't care much, just need to pick one, so would rather go with the most popular one
21:16:16
aeth
prove is broken for me now, in some private side thing where I had been using it 5+ years ago
21:16:43
aeth
the main thing prove offers over 5am iirc, having used both, is that prove will time its tests and show you how long it takes
22:07:19
ralt
Fare: google suggests yes, although I've never used it https://github.com/mcandre/cl-quickcheck