        (str-contains? t "comment") true
        (and (str-contains? t "string")
             (not
-             (and (end-pair? ch) (= \" left-ch) (not (= "string"
-                                                        (editor/->token-type ed (editor/adjust-loc loc 1))))))) true
+             (and (end-pair? ch) (= \" left-ch) (not (= "string" (editor/->token-type ed (editor/adjust-loc loc 1))))))) true
        :else false))))
 
 

(defn get-ch [ed loc]
  (get (editor/line ed (:line loc)) (:ch loc)))

(defn end-loc [ed]
  (let [last-line (editor/last-line ed)]
    {:line last-line
     :ch (max 0 (dec (editor/line-length ed last-line)))}))

(defn end-loc? [ed loc]
  (= (end-loc ed) loc))

(defn start-loc? [ed loc]
  (and (= 0 (:line loc))
       (= 0 (:ch loc))))


(defn string|comment? [ed loc]

                               (max (dec (editor/line-length ed (:line neue))) 0)
                               0))))))

(defn move-loc [ed dir loc & {:keys [line]}]
  (when loc
    (let [len (if line
                (count line)
                (editor/line-length ed (:line loc)))
          neue (editor/adjust-loc loc (if (= dir :left) -1 1))]
      (cond
       (< (:ch neue) 0) (move-loc-line ed loc :up)
       (>= (:ch neue) len) (move-loc-line ed loc :down)
       :else neue))))


(defn within-range [[start end] cur]
  (>= end (:line cur) start))



(defn loc-next-end-pair [ed loc]
