 ;; contents of the code-completion buffer with the new code-completion results
 ;; and ensures that the buffer is visible.
 (defun clang-completion-sentinel (proc event)
-  (let* ((all-lines (split-string clang-cc-result-string "\n"))
+  (let* ((all-lines (split-string clang-result-string "\n"))
          (completion-lines (filter 'is-completion-line all-lines)))
     (if (consp completion-lines)
         (progn

;; file up to the point where the cursor is located. Therefore, Clang
;; needs all of the various compilation flags (include paths, dialect
;; options, etc.) to provide code-completion results. Currently, these
;; need to be placed into the clang-cc-flags variable in a format
;; acceptable to clang-cc. This is a hack: patches are welcome to
;; improve the interface between this Emacs mode and Clang! 
;;

;;; Code:
;;; The clang-cc executable
(defcustom clang-cc "clang-cc"
  "The location of the clang-cc executable of the Clang compiler.
This executable is typically installed into the libexec subdirectory."
  :type 'file
  :group 'clang-completion-mode)

;;; Extra compilation flags to pass to clang-cc.
(defcustom clang-cc-flags ""
  "Extra flags to pass to the Clang executable.
This variable will typically contain include paths, e.g., -I~/MyProject."
  :type 'string

;;; The current completion buffer
(setq clang-completion-buffer nil)

(setq clang-result-string "")

;;; Compute the current line in the buffer	
(defun current-line ()
