Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 9 additions & 2 deletions inst/private/doctest_collect.m
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
%%
% Copyright (c) 2010 Thomas Grenfell Smith
% Copyright (c) 2015 Michael Walter
% Copyright (c) 2015-2019, 2022-2023 Colin B. Macdonald
% Copyright (c) 2015-2019, 2022-2024 Colin B. Macdonald
% Copyright (c) 2015 Oliver Heimlich
% Copyright (C) 2018 Mike Miller
% SPDX-License-Identifier: BSD-3-Clause
Expand Down Expand Up @@ -364,7 +364,14 @@

function [docstring, error] = extract_docstring(name)
if is_octave()
[docstring, format] = get_help_text(name);
try
[docstring, format] = get_help_text (name);
catch exc
docstring = '';
error = strcat ('Error extracting help text: ', ...
doctest_format_exception (exc));
return
end
if strcmp(format, 'texinfo')
[docstring, error] = parse_texinfo(docstring);
elseif strcmp(format, 'plain text')
Expand Down