Navigation Menu

Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't open man page for std::ref and others #15

Closed
k4rtik opened this issue May 29, 2016 · 9 comments
Closed

Can't open man page for std::ref and others #15

k4rtik opened this issue May 29, 2016 · 9 comments

Comments

@k4rtik
Copy link

k4rtik commented May 29, 2016

$ man std::ref
No manual entry for std::ref

while

$ man -k std::ref
std::ref,std::cref(3), std::ref(3), std::cref(3) - std::ref,std::cref
std::reference_wrapper(3) - std::reference_wrapper
std::reference_wrapper::get,std::reference_wrapper::operatorT&(3), std::reference_wrapper::get(3), std::reference_wrapper::operatorT&(3) - std::reference_wrapper::get,std::reference_wrapper::operatorT&
std::reference_wrapper::operator()(3) - std::reference_wrapper::operator()
std::reference_wrapper::operator=(3) - std::reference_wrapper::operator=
std::reference_wrapper::reference_wrapper(3) - std::reference_wrapper::reference_wrapper

The following works:

$ man std::ref,std::cref
@jeaye
Copy link
Owner

jeaye commented May 29, 2016

On Sat, May 28, 2016 at 08:08:42PM -0700, Kartik Singhal wrote:

$ man std::ref
No manual entry for std::ref

while

$ man -k std::ref
std::ref,std::cref(3), std::ref(3), std::cref(3) - std::ref,std::cref
std::reference_wrapper(3) - std::reference_wrapper
std::reference_wrapper::get,std::reference_wrapper::operatorT&(3), std::reference_wrapper::get(3), std::reference_wrapper::operatorT&(3) - std::reference_wrapper::get,std::reference_wrapper::operatorT&
std::reference_wrapper::operator()(3) - std::reference_wrapper::operator()
std::reference_wrapper::operator=(3) - std::reference_wrapper::operator=
std::reference_wrapper::reference_wrapper(3) - std::reference_wrapper::reference_wrapper

Hey there. The std::ref is grouped with std::cref on cppref, so they're
grouped automatically here, too. You can tell by reading the first line
of the man -k std::ref output, after the dash.

You need to run: man std::ref,std::cref

@k4rtik
Copy link
Author

k4rtik commented May 29, 2016

@jeaye yes, I figured that out, but it reduces the utility of man page. It would be awesome and save some keystrokes if one could just do a man std::ref or man std::cref and reach the same man page. Most C-related functions allow that, e.g. see man getc and man getchar.

@jeaye
Copy link
Owner

jeaye commented May 29, 2016

Agreed!

@k4rtik
Copy link
Author

k4rtik commented Jun 21, 2016

More annoyance when even search doesn't work:

$ man -k std::cin
std::cin: nothing appropriate.
$ man std::cin std::wcin
No manual entry for std::cin
No manual entry for std::wcin
$ man std::cin,std::wcin # works

@jeaye
Copy link
Owner

jeaye commented Jun 21, 2016

On Tue, Jun 21, 2016 at 11:41:11AM -0700, Kartik Singhal wrote:

More annoyance when even search doesn't work:

$ man -k std::cin
std::cin: nothing appropriate.
$ man std::cin std::wcin
No manual entry for std::cin
No manual entry for std::wcin
$ man std::cin,std::wcin # works

Searching should work, and the merging of those is a known issue (cppref
merges them into one page, so they end up as one man page). Have you run
sudo updatedb, as the install process suggests? Without it, your
searches won't work.

@k4rtik
Copy link
Author

k4rtik commented Jun 21, 2016

@jeaye oh yes, you are right. I recently installed stdman on a new Linux machine and probably missed to run the sudo mandb step (not updatedb). Works fine now. Thanks!

@jeaye
Copy link
Owner

jeaye commented Jun 21, 2016

On Tue, Jun 21, 2016 at 01:21:19PM -0700, Kartik Singhal wrote:

@jeaye oh yes, you were right. I recently installed stdman on a new Linux machine and probably missed to run the sudo mandb step (not updatedb). Works fine now. Thanks!

Ah, right my mistake. I keep it in the install process for people like
me, who forget the right commands all the time. :)

@rampion
Copy link

rampion commented Aug 10, 2016

As a workaround, some versions of man allow you to use * for globbing, so you can do man std::ref\*.

@k4rtik
Copy link
Author

k4rtik commented Jun 7, 2017

Closing this as things that I complained about seem to be working find now. 😄

@k4rtik k4rtik closed this as completed Jun 7, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants