anchor.diff:      member this.Source = src
       member this.ReplyChannel = replyChannel
   
  -
  -type MakeKernel<'t>(f, ?replyChannel:AsyncReplyChannel<Kernel<'t>>) =
  -    member this.Function = f
  -    member this.ReplyChannel = replyChannel
  -
  -
   type RunKernel<'t>(kernelRunFun, ?replyChannel:AsyncReplyChannel<Kernel<'t>>) =
       member this.KernelRunFunction = kernelRunFun
       member this.ReplyChannel = replyChannel
  -
  -
  -type Allocate<'t>(size) =
  -    member this.Size = size
  -type AllocateCrate =
  -    abstract member Apply : AllocateCrateEvaluator -> unit
  -
  -and AllocateCrateEvaluator =
  -    abstract member Eval<'a> : Allocate<'a> -> unit
   
   type ToHostCrate =
       abstract member Apply<'ret> : ToHostCrateEvaluator<'ret> -> 'ret
  
positive.code:     member this.ClDevice = device
  
      member this.ClContext = clContext
      member this.Allocate (alloc:AllocateCrate) =
              printfn "Allocation"
              let mutable result = Unchecked.defaultof<_>
              alloc.Apply
                  {
                      new AllocateCrateEvaluator
                      with member __.Eval (a) =
                              let length = a.Size
                              let buf = new Brahma.OpenCL.Buffer<_>(clContext, Brahma.OpenCL.Operations.ReadWrite, true, length)
                              let res = new GpuArray<'a>(buf,a.Size)
                              result <- res
                  }
              result
  
      member private this.HandleToGPU (queue:Brahma.OpenCL.CommandQueue, toGpu:ToGPUCrate) =
          toGpu.Apply
  
negative.code: and ToGPUCrateEvaluator<'ret> =
      abstract member Eval<'a> : ToGPU<'a> -> 'ret
  
  type Msg =
      | MsgToHost of ToHostCrate
      | MsgToGPU of ToGPUCrate
  