Skip to content

Commit 4685a4b

Browse files
committed
upd
1 parent 254bc2f commit 4685a4b

File tree

2 files changed

+6
-8
lines changed

2 files changed

+6
-8
lines changed

library.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
name=FastBot2
2-
version=1.0.14
2+
version=1.1.0
33
author=AlexGyver <[email protected]>
44
maintainer=AlexGyver <[email protected]>
55
sentence=Fast and universal Arduino/ESP8266/ESP32 library for Telegram bot

src/core/result.h

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ class Result : public gson::Entry {
1717
// освободить память
1818
void reset() {
1919
_parser.reset();
20+
gson::Entry::reset();
2021
}
2122

2223
// получить ридер
@@ -32,25 +33,22 @@ class Result : public gson::Entry {
3233
Result(Result& res) {
3334
move(res);
3435
}
35-
Result& operator=(Result& res) {
36+
Result(Result&& res) noexcept {
3637
move(res);
37-
return *this;
3838
}
39-
40-
#if __cplusplus >= 201103L
41-
Result(Result&& res) noexcept {
39+
Result& operator=(Result& res) {
4240
move(res);
41+
return *this;
4342
}
4443
Result& operator=(Result&& res) noexcept {
4544
move(res);
4645
return *this;
4746
}
48-
#endif
4947

5048
void move(Result& res) noexcept {
5149
if (this == &res) return;
5250
if (res) {
53-
_parser.move(res._parser);
51+
_parser = gtl::move(res._parser);
5452
*((gson::Entry*)this) = _parser.getByIndex(res.index());
5553
}
5654
_reader = res._reader;

0 commit comments

Comments
 (0)