Function: c-clear-char-property-with-value-on-char-function

c-clear-char-property-with-value-on-char-function is a byte-compiled function defined in cc-defs.el.gz.

Signature

(c-clear-char-property-with-value-on-char-function FROM TO PROPERTY VALUE CHAR)

Documentation

Remove all text-properties PROPERTY with value VALUE on characters with value CHAR from the region [FROM, TO), as tested by equal. These properties are assumed to be over individual characters, having been put there by c-put-char-property. POINT remains unchanged. Return the position of the first removed property, or nil.

Source Code

;; Defined in /usr/src/emacs/lisp/progmodes/cc-defs.el.gz
(defun c-clear-char-property-with-value-on-char-function (from to property
							       value char)
  "Remove all text-properties PROPERTY with value VALUE on
characters with value CHAR from the region [FROM, TO), as tested
by `equal'.  These properties are assumed to be over individual
characters, having been put there by c-put-char-property.  POINT
remains unchanged.  Return the position of the first removed
property, or nil."
  (let ((place from)
	first)
    (while			  ; loop round occurrences of (PROPERTY VALUE)
	(progn
	  (while	   ; loop round changes in PROPERTY till we find VALUE
	      (and
	       (< place to)
	       (not (equal (get-text-property place property) value)))
	    (setq place (c-next-single-property-change place property nil to)))
	  (< place to))
      (when (eq (char-after place) char)
	(remove-text-properties place (1+ place) (list property nil))
	(or first
	    (progn (setq first place)
		   (when (eq property 'syntax-table)
		     (setq c-syntax-table-hwm (min c-syntax-table-hwm place))))))
      ;; Do we have to do anything with stickiness here?
      (setq place (1+ place)))
    first))