Bug 251468 - nl_langinfo man page doesn't list legal inputs
Summary: nl_langinfo man page doesn't list legal inputs
Status: Closed FIXED
Alias: None
Product: Base System
Classification: Unclassified
Component: bin (show other bugs)
Version: CURRENT
Hardware: Any Any
: --- Affects Many People
Assignee: Yuri Pankov
URL: https://reviews.freebsd.org/D27606
Keywords:
Depends on:
Blocks:
 
Reported: 2020-11-29 21:55 UTC by Karl Williamson
Modified: 2020-12-24 23:46 UTC (History)
3 users (show)

See Also:
yuripv: mfc-stable12+


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Karl Williamson 2020-11-29 21:55:01 UTC
The parameter to this function is an enum nl_item.  The possible values are not given.  There is an example ABDAY_1, but searching for that in the entire documentation structure yielded nothing.
Comment 1 Yuri Pankov freebsd_committer 2020-11-29 22:53:48 UTC
Man page references the header containing recognized names:

The manifest constant names and values of item are defined in <langinfo.h>.
Comment 2 Karl Williamson 2020-12-01 16:39:36 UTC
If I could have easily found that header file, I would not have filed this bug.   What would have been most convenient would be for the text that names that hdr in the man page were to be a hyper link to the source of that file.

I tried searching the project for ABDAY_1 and got no results whatsoever
Comment 3 Yuri Pankov freebsd_committer 2020-12-14 14:33:53 UTC
I agree that having the recognized values in the man page would be helpful, more so knowing that those don't change often (if ever).
Comment 4 commit-hook freebsd_committer 2020-12-17 02:33:58 UTC
A commit references this bug:

Author: yuripv
Date: Thu Dec 17 02:33:52 UTC 2020
New revision: 368711
URL: https://svnweb.freebsd.org/changeset/base/368711

Log:
  nl_langinfo(3): document recognized item names

  While here, remove .Tn macro usage (prompted by mandoc lint).

  PR:		251468
  Reviewed by:	bapt
  Differential Revision:	https://reviews.freebsd.org/D27606

Changes:
  head/lib/libc/locale/nl_langinfo.3