On Tue, Jul 23, 2013 at 03:36:28PM +0200, Stefan Hajnoczi wrote: > On Tue, Jul 23, 2013 at 01:10:35PM +0100, Gabriel Kerneis wrote: > > On Tue, Jul 23, 2013 at 02:05:15PM +0200, Stefan Hajnoczi wrote: > > > A built-time check for coroutine_fn would be valuable if we ever hope to > > > get disciplined with this annotation. > > > > > > The check can detect when a coroutine_fn is invoked outside coroutine > > > context. I wonder if Coccinelle can detect this, although I never > > > figured out how to use it as a grep-like tool instead of just a > > > patch-like tool. > > > > The recent "cps-inference" branch of CPC enables precisely that kind of > > check. > > Charlie is using it to drive his modifications to QEMU and has already > > suggested > > several improvements that I have implemented. Hopefully we should reach > > something fully covering QEMU by the end his GSoC. > > > > If there is interest, I can post a script showing how to build it and use > > it to > > check QEMU annotations (it does not require any modifications to QEMU, only > > a > > couple of configure switches). > > What is the status of CPC packaging in distros?
There will be an opam [1] package for it before the end of the week (based on the CIL release planned for tomorrow). I've also been working on a Debian package but it's not ready yet unfortunately. [1] http://opam.ocamlpro.com/ -- Gabriel