File tree 1 file changed +16
-4
lines changed
1 file changed +16
-4
lines changed Original file line number Diff line number Diff line change @@ -513,16 +513,28 @@ class Text : public Printable {
513
513
// ========================== CONVERT ==========================
514
514
515
515
// Вывести в String строку. Вернёт false при неудаче
516
- bool toString (String& s, bool decodeUnicode = false ) const {
516
+ bool toString (String& s) const {
517
+ s = " " ;
518
+ return addString (s);
519
+ }
520
+
521
+ // Вывести в String строку. Вернёт false при неудаче
522
+ bool toString (String& s, bool decodeUnicode) const {
517
523
s = " " ;
518
524
return addString (s, decodeUnicode);
519
525
}
520
526
521
527
// Получить как String строку
522
- String toString (bool decodeUnicode = false ) const {
523
- if (!valid () || !_len) return String ();
528
+ String toString () const {
529
+ String s;
530
+ addString (s);
531
+ return s;
532
+ }
533
+
534
+ // Получить как String строку
535
+ String toString (bool decodeUnicode) const {
524
536
String s;
525
- toString (s, decodeUnicode);
537
+ addString (s, decodeUnicode);
526
538
return s;
527
539
}
528
540
You can’t perform that action at this time.
0 commit comments