     (with-check err (aget res 0))))
 
 (defn kernels
-  ([program ^String name]
+  ([program name]
    (let [err (int-array 1)
          res (CL/clCreateKernel program name err)]
      (with-check-arr err res)))

   (set-event-callback channel e CL/CL_COMPLETE nil)))

;; ============= Program ==========================================

(defn program-with-source
  ([context source]

         err (CL/clCreateKernelsInProgram program nk res nil)]
     (vec (with-check err res)))))

(defn set-arg! [kernel n cl-mem]
  (set-arg cl-mem kernel n))

(defn set-args!
  ([kernel cl-mem]
   (set-arg! kernel 0 cl-mem))
  ([kernel cl-mem-0 cl-mem-1]
   (-> (set-arg! kernel 0 cl-mem-0)
       (set-arg! 1 cl-mem-1)))
  ([kernel cl-mem-0 cl-mem-1 cl-mem-2]
   (-> (set-arg! kernel 0 cl-mem-0)
       (set-arg! 1 cl-mem-1)
       (set-arg! 2 cl-mem-2)))
  ([kernel cl-mem-0 cl-mem-1 cl-mem-2 cl-mem-3 & cl-mems]
   (let [ker (-> (set-arg! kernel 0 cl-mem-0)
                 (set-arg! 1 cl-mem-1)
                 (set-arg! 2 cl-mem-2)
                 (set-arg! 3 cl-mem-3))]
     (loop [i 4 cl-mems cl-mems]
       (if-let [mem (first cl-mems)]
         (do (set-arg! ker i mem)
             (recur (inc i) (next cl-mems)))
         ker)))))

;; ============== Command Queue ===============================

