Mihail
And you add another (which leaves an empty line)
Elnee
Oh... really
Elnee
I'm sorry that was easy
Mihail
No problem
Elnee
Thank you :)
Anonymous
Hi there ✨
Mat
Hey!
Dima
welcome
german oak
С с++ чтиво для нуба есть? На русском?
klimi
It's in English thought
klimi
Sorry
:) no problem
klimi
I'm in good mood
german oak
Anyone have any books about c, cpp for absolutely noob on russian?
klimi
Anyone have any books about c, cpp for absolutely noob on russian?
There is pinned msg with rules, no book request. Only in English, I'm sorry but I don't think anyone has c++ book in Russian
klimi
We can't support piracy
german oak
We can't support piracy
Ah, ok. Just in ryssia all support piracy. Everyone. We have specian social network for it. Vk.com
german oak
klimi
Ah, ok. Just in ryssia all support piracy. Everyone. We have specian social network for it. Vk.com
This group is multinacional and admins and users are taking responsibility not to pirate stuff on telegram
klimi
It's against the rules
klimi
I know piracy is heavily relied on many countries..
german oak
I stand. Ok
klimi
I stand. Ok
http://gen.lib.rus.ec
Aiman
hi. im wanna asking , can we put a passing by reference parameter with an array ??
olli
hi. im wanna asking , can we put a passing by reference parameter with an array ??
When passing an array (T[]) as parameter it basically decays to a pointer to the type of the array (T*). So changes made to the array are visible from the calling function
Леонтий
Anyone have any books about c, cpp for absolutely noob on russian?
Hi! I've read Herbert Schildt's book, it's very easy to get. it is "C++ Базовый курс" in Russian
Anonymous
thanks everyone
Akhi
Who teach me C and C++....Sent Pm
Anonymous
Google
Akhi
😱😱
german oak
Dima
Lol
Dima
These people lol
Dima
😂
klimi
These people lol
Dima teach me :<
Dima
Dima teach me :<
You need unique bio because of the unique key or what, change your database
klimi
Dima....
Walter
Hello
Liam
hi
Anonymous
How to find all adjacent Element of matrix I searched on Google but I am only able to find only adjacents of Element which is center of matrix but I also want to find adjacents of core side Element of given matrix???
Silvestr
Hello all) howI can cast from rvalue to lvalue?
Liam
Silvestr
assign it to a named variable.
maybe any other way to do it)?
Silvestr
maybe some std:: func?
Liam
maybe any other way to do it)?
Please consider to express your original problem? Casting rvalue to lvalue is somewhat strange.
Silvestr
Please consider to express your original problem? Casting rvalue to lvalue is somewhat strange.
In class I have copy and move constructor, but I assign it from function something like this object = myFunc(); And in this situation is called move costructor but I need copy
MrSmith
Hi guess I need C code which write 1960-1970
MrSmith
It good if it have many goto
Silvestr
It good if it have many goto
it's normal if you know what are you doing)
Mat
It good if it have many goto
It's not good nowadays
MrSmith
A meen I try dig old code between this years with many goto
MrSmith
Please no holywars I just need cod
Mat
goto is fast) its just asm jump
It's not clear and not recommended this days
Silvestr
but it creates a lot of bus if you don't completely undertand what you do
Dima
Silvestr
A meen I try dig old code between this years with many goto
https://github.com/libssh2/libssh2/blob/master/src/openssl.c
Silvestr
enjoy
Silvestr
So what about casting to lvalue without creation separate var?
MrSmith
So it is very new code
Liam
In class I have copy and move constructor, but I assign it from function something like this object = myFunc(); And in this situation is called move costructor but I need copy
I'm not quite understand why you need copy constructor here. And for your codes, it won't call a copy/move constructor, sinc RVO will optimize the unecessary copy/move.
Liam
In this situation, RVO erase the unecessary copy. It just won't happen.
Liam
I need copy of this object) I can create method for that but ...
Try this: #include <iostream> struct Foo { int member = 0; Foo() { std::cout << "Foo::Foo().\n"; } explicit Foo(int m) : member(m) { std::cout << "Foo::Foo(int).\n"; } Foo(const Foo& foo) : member(foo.member) { std::cout << "Foo::Foo(const Foo&).\n"; } Foo(Foo&& foo) : member(foo.member) { foo.member = 0; std::cout << "Foo::Foo(Foo&&).\n"; } Foo& operator=(const Foo& foo) { member = foo.member; std::cout << "Foo::operator=(const Foo&).\n"; return *this; } Foo& operator=(Foo&& foo) { member = foo.member; foo.member = 0; std::cout << "Foo::operator=(Foo&&).\n"; return *this; } }; Foo func(int m) { return Foo(m); } int main() { Foo foo = func(42); return 0; }
Liam
Result: $ ./a.out Foo::Foo(int).
Silvestr
Result: $ ./a.out Foo::Foo(int).
is just calls one constructor(
Liam
Liam
If you just wanna see the calling of copy constructor, you could write something like this: Foo foo = func(42); Foo foo_ = foo; Foo foo__(foo); But in real-world-codes, it's useless.