Message from C, C++ talks

July 2019

— One need to know hella lot terms and principles to understand conxtexpr conditions

— It may sound easy for one who faced this things a lot

— I don't even understand all of them. I just program functions normally, mark them as contexpr and wait for the compiler to tell me what's wrong and adapt as I go

Message permanent page

— Just avoid dynamic allocations and you're good to go

— 

They're not used for everything, but if you think your function is quite simple, just mark it as constexpr and the compiler will execute at compile time everytime it can

— A lot of work for like fifth example after hello world

— It's not that difficult. You just want to know EVERYTHING, which isn't really necessary

— > mark them as contexpr and wait for the compiler to tell me what's wrong and adapt as I go
That's a way actually. But what we want them to learn is const. And slapping constexpr everywhere explains neither const nor constexpr

Message permanent page

— I admit I may've crossed a line, but I do think every single word in a program should be clear to one who writes it, especially if one learns a language

Message permanent page

— Isn't the keyword constexpr clear enough to you?

— It's clear as a term, but not it's usages and restrictions

— Like, with C++20 we will be able to do constexpr funcs virtual and have try blocks inside

— There are similar differences in 11/14

— There's few restrictions. An important one is that the code can't invoke undefined behaviour, which is pretty sensible

Message permanent page

— Hey guys , is there a way to buggy a directory list crawler in c++?