Pavel
About volatile, just yesterday seen this video.
https://www.youtube.com/watch?v=lkgszkPnV8g
Guys in Facebook made a check on some continuous integration machine that comments a paragraph about "volatile doesn't make your code thread-safe" into the code review, when it finds volatile going to be submitted not in a comment.
Daniele°
Pavel
Yes, but I for a long time thought that volatile bool can be used as a synchronization primitive. Before someone told me why it's not.
And there recently was a local conference in my city related to multithreading, and there were such code with volatile bool, and I've been told that there was a question from the audience and a long discussion, and it turned out that many of those who come to the conference thought it's an ok practice.
BinaryByter
BinaryByter
Pavel
Ah and also I heard that VS make volatile bool atomic by default. So it can work sometimes. But not sure if that true or rumors
Parra
Parra
Parra
Parra
Parra
https://docs.microsoft.com/en-us/cpp/cpp/volatile-cpp?view=vs-2019
Anonymous
What is difference between codeblocks and opencv
Vitaliy ◀️TriΔng3l▶️
Parra
Vitaliy ◀️TriΔng3l▶️
google both?
Anonymous
Yeah
Dima
Lol!
BinaryByter
BinaryByter
OpenCV is a framework to do computervision in CPP
BinaryByter
You CAN use opencv in codeblocks thpugh
Dima
that kind of questions, how come these even get in their brains lol.
BinaryByter
Dima
Yeah, but that range is large
BinaryByter
meh
Anonymous
Anonymous
best way to learn programming?
void
Anonymous
wow bro.. what an idea
void
* learn everything that you like and solve a lot of problems *
SjD
any way to share large files using regular lan cable?
SjD
between laptop &pc
SjD
i went to network,they're not showing up
void
Get ip addresses of your devices
SjD
ok,and then?
BinaryByter
void
Then you will know the address of your device and you'll be able to send anything to this address
SjD
ok ill try
Dima
void
If you're using Linux system — just $ scp file
Dima
People want to learn programming tips but they want to do this an easy way.
BinaryByter
Dark
std::cout << “boring” << endl;
Dima
Lol, endl.
Dark
Lol, endl.
Sorry I keep it old school. None of this “/n” shit
Dima
read about how it works and then call \n “shit"
Dima
#noendl
Anonymous
Can any one tell me what is callback function in C
Anonymous
It'll be helpful if someone reply
void
Anonymous
The function which has function pointer declared in the brackets right
Anonymous
Is the call back function
Anonymous
Right?
Anonymous
Or the function which passes it's address to that function
Anonymous
Can you tell.
void
Callback fucntion is the function that will be executed after some code by reference
Mihail
Sorry I keep it old school. None of this “/n” shit
you do realize you're simply making a fool of yourself, by 1) not even knowing what a line ending is and 2) implying that flushing on every newline is apparently not shit, while simply putting a newline character and flushing when neccessary is shit
Mihail
also how the fuck is std::endl oldschool compared to '\n'?
void
Old-school is C programming without std:: 🌝
BinaryByter
BinaryByter
Oh wait sorry, i misread
BinaryByter
just cout 0x13 and 0x10
Foxner
What does flushing stdout actually do?
BinaryByter
🤷♀😂
BinaryByter
when its filled, it will outout the array
BinaryByter
instead of outputting on every string it gets
Foxner
When is it considered filled?
BinaryByter
when theres no more place
Wim
stack overflow, segsev 😂
BinaryByter
BinaryByter
That came in so random, i'll hook your messages up to my RNG
Foxner
But using cout without endl works fine. What causes the buffer to be flushed then?
BinaryByter
BinaryByter
the destructor flushes the buffer
BinaryByter
or when the buffer is too full, as said
Foxner
BinaryByter
its a function that is called when the object is removed from memory