]> gitweb.factorcode.org Git - factor.git/commitdiff
FUEL: Fixes to fuel-update-usings.
authorJose A. Ortega Ruiz <jao@gnu.org>
Wed, 24 Dec 2008 01:44:49 +0000 (02:44 +0100)
committerJose A. Ortega Ruiz <jao@gnu.org>
Wed, 24 Dec 2008 01:44:49 +0000 (02:44 +0100)
misc/fuel/fuel-debug-uses.el
misc/fuel/fuel-syntax.el

index 2930eff4d64bd90b474eb318304b1ad65682d045..bdcc511a3bf4075fda9d39c9f9e72e3f69135745 100644 (file)
@@ -35,9 +35,6 @@
 \f
 ;;; Utility functions:
 
-(defsubst fuel-debug--at-eou-p ()
-  (looking-at ".*\\_<;\\_>"))
-
 (defun fuel-debug--file-lines (file)
   (when (file-readable-p file)
     (with-current-buffer (find-file-noselect file)
         (let ((lines) (in-usings))
           (while (not (eobp))
             (when (looking-at "^USING: ") (setq in-usings t))
-            (unless in-usings
-              (let ((line (substring-no-properties (thing-at-point 'line) 0 -1)))
-                (unless (or (empty-string-p line)
-                            (fuel--string-prefix-p "! " line))
-                  (push line lines))))
-            (when (and in-usings (fuel-debug--at-eou-p)) (setq in-usings nil))
+            (let ((line (substring-no-properties (thing-at-point 'line) 0 -1)))
+              (when in-usings (setq line (concat "! " line)))
+              (push line lines))
+            (when (and in-usings (looking-at ".*\\_<;\\_>")) (setq in-usings nil))
             (forward-line))
           (reverse lines))))))
 
index 04cf0e615c017ee5082832fd9e3cb0a72eb8ba8f..eeca09865d270075bdf9e633f68d9fb1342d63fd 100644 (file)
 
 (defun fuel-syntax--find-usings ()
   (save-excursion
-    (let ((usings)
-          (in (fuel-syntax--current-vocab)))
-      (when in (setq usings (list in)))
+    (let ((usings))
       (goto-char (point-max))
       (while (re-search-backward fuel-syntax--using-lines-regex nil t)
         (dolist (u (split-string (match-string-no-properties 1) nil t))