Function: semantic-python-docstring-p

semantic-python-docstring-p is a byte-compiled function defined in python.el.gz.

Signature

(semantic-python-docstring-p TAG)

Documentation

Return non-nil, when TAG is a Python documentation string.

Source Code

;; Defined in /usr/src/emacs/lisp/cedet/semantic/wisent/python.el.gz
(defun semantic-python-docstring-p (tag)
  "Return non-nil, when TAG is a Python documentation string."
  ;; TAG is considered to be a documentation string if the first
  ;; member is of class 'code and its name looks like a documentation
  ;; string.
  (let ((class (semantic-tag-class tag))
	(name  (semantic-tag-name  tag)))
    (and (eq class 'code)
	 (string-match
	  (rx (seq string-start "\"\"\"" (0+ anything) "\"\"\"" string-end))
	  name))))