[climacs-cvs] CVS climacs

thenriksen thenriksen at common-lisp.net
Tue May 8 10:23:10 UTC 2007


Update of /project/climacs/cvsroot/climacs
In directory clnet:/tmp/cvs-serv21088

Modified Files:
	c-syntax.lisp 
Log Message:
As with Java-syntax, remove evil indentation-corrupting function
redefinition.


--- /project/climacs/cvsroot/climacs/c-syntax.lisp	2007/05/01 20:54:53	1.2
+++ /project/climacs/cvsroot/climacs/c-syntax.lisp	2007/05/08 10:23:09	1.3
@@ -1329,27 +1329,13 @@
 	  do (incf (offset mark2))
           finally (return column))))
 
-(defun line-indentation (mark tab-width syntax)
-  "Return the column of the first non-whitespace object, or nil."
-  (setf mark (clone-mark mark))
-  (beginning-of-line mark)
-  (loop until (end-of-line-p mark)
-	while (whitespacep syntax (object-after mark))
-	with column = 0
-	if (eql (object-after mark) #\Tab)
-	  do (incf column (- tab-width (mod column tab-width)))
-	else
-	  do (incf column)
-	do (forward-object mark)
-	finally (return (if (end-of-line-p mark) nil column))))
-
 (defmethod syntax-line-indentation (mark tab-width (syntax c-syntax))
   (setf mark (clone-mark mark))
-  (let ((this-indentation (line-indentation mark tab-width syntax)))
+  (let ((this-indentation (line-indentation mark tab-width)))
     (beginning-of-line mark)
     (loop until (beginning-of-buffer-p mark)
 	  do (previous-line mark 0)
-	  when (line-indentation mark tab-width syntax)
+	  when (line-indentation mark tab-width)
 	    return it
 	  finally (return this-indentation))))
 




More information about the Climacs-cvs mailing list