diff options
| author | Julian Hurst <ark@mansus.space> | 2022-06-15 15:57:14 +0200 |
|---|---|---|
| committer | Julian Hurst <ark@mansus.space> | 2023-09-07 00:06:57 +0200 |
| commit | b751405435e7f41837902046a5271c30f720e69a (patch) | |
| tree | 6d94299352b9a7f77742ba0e41c848531794de53 /libtui | |
| parent | faa53815a7bf84e87e89152cfc2507d395ac8af9 (diff) | |
| download | hare-libtui-b751405435e7f41837902046a5271c30f720e69a.tar.gz | |
Specify borrowing in list::selected comment
Diffstat (limited to 'libtui')
| -rw-r--r-- | libtui/widget/list/list.ha | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/libtui/widget/list/list.ha b/libtui/widget/list/list.ha index 611b4ae..583c1af 100644 --- a/libtui/widget/list/list.ha +++ b/libtui/widget/list/list.ha @@ -340,8 +340,8 @@ export fn regexmark(l: *listwidget, re: *regex::regex) void = { }; }; -// Returns the selected item or marked items if there are any. If []str is -// returned it must be freed. +// Returns the selected item or marked items if there are any. The returned +// value is borrowed from the list's items. export fn selected(l: listwidget) (str | []str) = { if (len(l.marked.items) > 0) { let result: []str = []; |
