Skip to content

Commit 2d1ea27

Browse files
committed
publish: validate function name in docstring
1 parent 5d9d9b9 commit 2d1ea27

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

+stdlib/checkRAM.m

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
%% CHECKRAN estimate if RAM will fit a new array
1+
%% CHECKRAM estimate if RAM will fit a new array
22
% checks that requested memory for the new array won't exceed AVAILABLE RAM with Matlab
33
%
44
% This script is optimistic as Matlab won't always be able to

buildfile.m

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -90,6 +90,9 @@ function publishTask(~)
9090
words = split(strip(summary(1)), " ");
9191
% purposefully this will error if no docstring
9292
fname = words(1);
93+
if(lower(fname) ~= lower(name))
94+
error("fname %s does not match name %s", fname, name)
95+
end
9396
line = "<a href=" + name + ".html>" + fname + "</a> ";
9497
if(length(words) > 1)
9598
line = line + join(words(2:end));

0 commit comments

Comments
 (0)