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

Explore relationship between grammar::string_view_base and std::string_view #881

Open
alandefreitas opened this issue Nov 11, 2024 · 0 comments

Comments

@alandefreitas
Copy link
Member

Can someone derive from std::string_view as an alternative to deriving from boost::urls::grammar::string_view_base?

string_view_base stores a core::string_view and is a proxy for its member functions. In principle and semantically, it's guaranteed that string_view_base is OK to use as a base class while std::string_view or core::string_view are not. In practice, string_view_base has no virtual functions and doesn't have a virtual destructor.

The only class that refers to and derives from it is pct_string_view, making it inherit the usual member functions of a string_view.

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

1 participant