RobLoach / raylib-cpp

C++ Object Oriented Wrapper for raylib
https://robloach.github.io/raylib-cpp/
zlib License
584 stars 77 forks source link

`string_view` instead of `string`? #318

Closed RobLoach closed 6 days ago

furudbat commented 6 days ago

One problem with std::string_view is, it's not guaranteed to be a null-terminated string.

I would love to replace const std::string& with something like std::string_view, but I wouldn't recommend it.

We probably need something like zstring_view. Shouldn't be that hard to implement

RobLoach commented 6 days ago

Agreed, and because performance isn't the primary goal of this library, it may not be worth its adoption.