# HG changeset patch # User Rik # Date 1378875619 25200 # Node ID 3611ebb0ad8881af1db5e0081086ceb9ed176efc # Parent 3f0ed69d21c6d22b00a9259b9096df196c119858 doc: Add operator and keyword docstrings missing from lookfor cache. * doc/interpreter/mk_doc_cache.m: Append operator and keyword docstrings to file containing function docstrings before passing through makeinfo. diff -r 3f0ed69d21c6 -r 3611ebb0ad88 doc/interpreter/mk_doc_cache.m --- a/doc/interpreter/mk_doc_cache.m Tue Sep 10 18:31:39 2013 -0700 +++ b/doc/interpreter/mk_doc_cache.m Tue Sep 10 22:00:19 2013 -0700 @@ -48,10 +48,22 @@ endif endif endfor -text = [text{:}, doc_delim]; +text = [text{:}]; + +## Strip Texinfo marker +text = regexprep (text, "-\\*- texinfo -\\*-[ \t]*[\r\n]*", ""); -## Strip Texinfo markers and docstring separators. -text = regexprep (text, "-\\*- texinfo -\\*-[ \t]*[\r\n]*", ""); +## Add keywords and operators +other_docstrings = [__keywords__; __operators__]; +for i = 1 : numel (other_docstrings) + name = other_docstrings{i}; + ## Special handling of block comment operators such as '#{' + esc_name = regexprep (name, '([{}])', '@$1'); + text = [text doc_delim esc_name get_help_text(name) "\n"]; +endfor +text(end+1) = doc_delim; + +## Double '@' symbol for Texinfo text = strrep (text, [doc_delim "@"], [doc_delim "@@"]); ## Write data to temporary file for input to makeinfo