Skip to content

Commit 7963a59

Browse files
author
Matthias Kastner
committed
extend ProcGlobal check
if a procedure lives in ProcGlobal, its module is sometimes specified as an empty string. See for example the module string from `FunctionInfo`. Since this check is used to output the procedure with module string as of `Procedure [Module]` an empty Module would produce `Procedure []` instead of `Procedure`.
1 parent 662a43b commit 7963a59

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

procedures/CodeBrowser_utils.ipf

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,10 +53,17 @@ Function/S addToItemsInList(list, [sep, suffix, prefix])
5353
return resultList
5454
End
5555

56+
// check if the specified module is ProcGlobal
57+
//
58+
// @param module string containing the module name
59+
// @returns 1 if @p module is an empty string or equal to `ProcGlobal`
5660
Function isProcGlobal(module)
5761
string module
5862

59-
return cmpstr(module, "ProcGlobal") == 0
63+
if(strlen(module) == 0 || !cmpstr(module, "ProcGlobal"))
64+
return 1
65+
endif
66+
return 0
6067
End
6168

6269
// Returns the dimension of the first screen

0 commit comments

Comments
 (0)