It took c++ over 40 years to get a fucking contains method on strings

>it took c++ over 40 years to get a fucking contains method on strings.
support for splitting strings is coming in c++47
and support for switching on strings in c++76

networking? getting delayed again LOL
reflection? what's that? LOL

Attached: 43453345.jpg (1888x803, 145K)

Other urls found in this thread:

github.com/fmtlib/fmt
twitter.com/NSFWRedditVideo

The fuck is a std::print? I thought we do std::cout

>support for splitting strings is coming in c++47
Already exists in C++20
#include
#include
#include
#include

int main() {
constexpr std::string_view words{"Hello-_-C++-_-20-_-!"};
constexpr std::string_view delim{"-_-"};
for (const auto word : std::views::split(words, delim)) {
std::cout

C++ is such a beautiful language. Fuck Rust!

Sepples' standard will one day swell to encompass the whole universe, but compilers will only support a small part of it, I'm sure.

>std::print
that's the new hottest thing. c++ will soon have three ways of printing to the console.

Attached: 434533345.jpg (1262x510, 65.68K)

why would I need to bother with the standard library catching up when 9/10 some poo code from stackoverflow is just as good for adding to your own custom standard library

Damn C++ will have feature parity with Python by 2050

God that is fucking disgusting to read

holy fuck an actually reasonable API.
Never thought I'd see the day

C++ and Rust are crimes against beauty. Why do people make programming languages so goddamn ugly?
Java is way more readable despite all the hate it gets.

I'm starting to think that the Stroustrup interview posted on cat-v actually wasn't a joke.

it's reasonable because it was basically lifted from a library some guy made
github.com/fmtlib/fmt

Why are Sepples fans so scared of using namespace std? It would make this super ugly snippet a bit less ugly.

Probably the dumbest thing I've ever read here. Congrats

Java is in fact more readable.

I stay with python thanks.

Leave Rust out of this.
for word in "Hello-_-C++-_-20-_-!".split("-_-") {
println!("{word}");
}

It's also the only sane way to design what it's supposed to do. If you try implementing something supporting what fmt supports you end up with exactly the same thing as what they ended up with, it's actually pretty incredible.

Name lookup for functions in C++ is fundamentally broken. Any code that uses functions without qualifying them is bad code as a result. Yes C++ is a shitty language. Blame Andrew Koenig

>wanting strings support when arrays of characters exists
>wanting networking for a platform-agnostic language
>wanting the mess that is reflection
Embrace simplicity and true control, embrace C.

20 more years and it gets toUpper

>Python-style formatting
When did this happen?

>Any code that uses functions without qualifying them is bad code as a result.
This does not follow from your premise. Literally nothing wrong with using directives in source files (in fact, I have yet to see a real world C++ codebase that DIDN'T use them). ADL can still bite you in the ass with fully qualified names anyway.

Avoiding using directives like the plague is a dumb StackOverflow cult that defies the purpose of namespaces. At this point, you're better off using pre_fixes like it's usually done in C libraries.