]> code.delx.au - gnu-emacs-elpa/commitdiff
Removed CL case statement from lambda, because it needs CL at run-time.
authorNikolaj Schumacher <git@nschum.de>
Fri, 17 Apr 2009 09:19:13 +0000 (11:19 +0200)
committerNikolaj Schumacher <git@nschum.de>
Sat, 18 Apr 2009 11:06:47 +0000 (13:06 +0200)
company.el

index e5c81dc075f99d85391515cc309103c0a4149e81..b689778021826c99e5bdd540cab69bb2798f7b9f 100644 (file)
@@ -1347,12 +1347,14 @@ Example:
    (let ((start (- (point) (or prefix-length 0))))
      (setq company-begin-with-marker (copy-marker (point) t))
      `(lambda (command &optional arg &rest ignored)
-        (case command
-          ('prefix (when (equal (point)
-                                (marker-position company-begin-with-marker))
-                     (buffer-substring ,start (point))))
-          ('candidates (all-completions arg ',candidates))
-          ('require-match ,require-match))))
+        (cond
+         ((eq command 'prefix)
+          (when (equal (point) (marker-position company-begin-with-marker))
+            (buffer-substring ,start (point))))
+         ((eq command 'candidates)
+          (all-completions arg ',candidates))
+         ((eq command 'require-match)
+          ,require-match))))
    callback))
 
 ;;; pseudo-tooltip ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;