aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--docs/magit-section.org5
-rw-r--r--docs/magit-section.texi5
-rw-r--r--lisp/magit-section.el5
3 files changed, 8 insertions, 7 deletions
diff --git a/docs/magit-section.org b/docs/magit-section.org
index f94ef15..f0477f5 100644
--- a/docs/magit-section.org
+++ b/docs/magit-section.org
@@ -171,10 +171,11 @@ source for suitable examples before asking me for help. Thanks!
If optional ROOT is non-nil, then search in that section tree
instead of in the one whose root ~magit-root-section~ is.
-- Function: magit-section-lineage section ::
+- Function: magit-section-lineage section &optional raw ::
Return the lineage of SECTION.
- The return value has the form ~(TYPE...)~.
+ If optional RAW is non-nil, return a list of section objects,
+ beginning with SECTION, otherwise return a list of section types.
- Function: magit-section-content-p section ::
diff --git a/docs/magit-section.texi b/docs/magit-section.texi
index f0f4365..b59635b 100644
--- a/docs/magit-section.texi
+++ b/docs/magit-section.texi
@@ -216,9 +216,10 @@ If optional ROOT is non-nil, then search in that section tree
instead of in the one whose root @code{magit-root-section} is.
@end defun
-@defun magit-section-lineage section
+@defun magit-section-lineage section &optional raw
Return the lineage of SECTION@.
-The return value has the form @code{(TYPE...)}.
+If optional RAW is non-nil, return a list of section objects,
+beginning with SECTION, otherwise return a list of section types.
@end defun
@defun magit-section-content-p section
diff --git a/lisp/magit-section.el b/lisp/magit-section.el
index 25e71c1..656a91c 100644
--- a/lisp/magit-section.el
+++ b/lisp/magit-section.el
@@ -596,9 +596,8 @@ instead of in the one whose root `magit-root-section' is."
(defun magit-section-lineage (section &optional raw)
"Return the lineage of SECTION.
-If optional RAW is non-nil, return a list of section object
-beginning with SECTION, otherwise return a list of section
-types."
+If optional RAW is non-nil, return a list of section objects, beginning
+with SECTION, otherwise return a list of section types."
(cons (if raw section (oref section type))
(and-let* ((parent (oref section parent)))
(magit-section-lineage parent raw))))