[Bug 296050] sh.1: Description of 'local' is not very clear
- In reply to: bugzilla-noreply_a_freebsd.org: "[Bug 296050] sh.1: Description of 'local' is not very clear"
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Sat, 20 Jun 2026 19:03:30 UTC
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=296050
--- Comment #5 from commit-hook@FreeBSD.org ---
A commit in branch stable/14 references this bug:
URL:
https://cgit.FreeBSD.org/src/commit/?id=cee36a5e003c90659f274a2f20699543c73f2d34
commit cee36a5e003c90659f274a2f20699543c73f2d34
Author: Dag-Erling Smørgrav <des@FreeBSD.org>
AuthorDate: 2026-06-16 20:23:18 +0000
Commit: Dag-Erling Smørgrav <des@FreeBSD.org>
CommitDate: 2026-06-20 19:02:53 +0000
sh: Improve function documentation
* Mention that the function body can be in parentheses. It is already
implied since the function body can be any valid statement, but it may
not be obvious to a reader who has only ever seen functions that used
curly brackets and assumes that they are part of the function syntax.
* Remove the incorrect claim that a local statement may only occur at
the top of a function.
* Show that a value may be assigned to a variable in a local statement.
* While here, replace unpaired double quotes with \(dq to avoid
confusing syntax highlighters.
PR: 296050
MFC after: 1 week
Reviewed by: ziaee, jilles
Differential Revision: https://reviews.freebsd.org/D57596
(cherry picked from commit 556e793d803e12e9ad9361c6c53ed0433151f41e)
sh: Belatedly bump manual page date
Fixes: 556e793d803e ("sh: Improve function documentation")
(cherry picked from commit 09bb0b0d13968163c7394e9168491b16607fc2e7)
bin/sh/sh.1 | 27 +++++++++++++++++----------
1 file changed, 17 insertions(+), 10 deletions(-)
--
You are receiving this mail because:
You are on the CC list for the bug.