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

emit doc/uri facts for C++ standard library names pointing to en.cppreference.com #5374

Open
shahms opened this issue Sep 13, 2022 · 3 comments
Assignees
Labels
C++ Issues affecting C++ enhancement wishlist Issues which would be nice to have

Comments

@shahms
Copy link
Contributor

shahms commented Sep 13, 2022

We create doc nodes and edges from comments present in code. These are almost universally lacking for C++ standard library implementations.

It should, however, be fairly straightforward to map from the standard library symbol definitions to the corresponding page on en.cppreference.com using the Doxygen tagfile present in the offline HTML book archive: https://en.cppreference.com/w/Cppreference:Archives

The doxygen tagfile format is, sadly, XML and I'm not particularly enthusiastic about growing an XML parser dependency.

@shahms shahms added enhancement C++ Issues affecting C++ wishlist Issues which would be nice to have labels Sep 13, 2022
@shahms shahms self-assigned this Sep 13, 2022
@creachadair
Copy link
Contributor

For simple purposes I've had good luck using https://pkg.go.dev/encoding/xml, which is in the standard library. It's not good for complex schemata, but probably fine for scraping doc links out of a ToC.

@shahms
Copy link
Contributor Author

shahms commented Sep 13, 2022

tagfiles are thankfully pretty simple, but the C++ indexer is C++ after all, but we could just use Go to translate the XML doc to protobuf or something

@creachadair
Copy link
Contributor

tagfiles are thankfully pretty simple, but the C++ indexer is C++ after all, but we could just use Go to translate the XML doc to protobuf or something

Yeah, I was thinking of a preprocessing step, since presumably it only needs to be updated occasionally.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C++ Issues affecting C++ enhancement wishlist Issues which would be nice to have
Projects
None yet
Development

No branches or pull requests

2 participants