670 {
672
673 bool is_numeric = false;
674
676 case 's':
677 if (arg) {
679 } else {
681 }
682 break;
683 case 'p': {
684
685 is_numeric = true;
686 const void* ptr = static_cast<const void*>(arg);
687 fl::uptr addr = reinterpret_cast<fl::uptr>(ptr);
689 break;
690 }
691 case 'x':
692 result =
"<string_not_hex>";
693 break;
694 case 'd':
695 case 'i':
696 case 'u':
697 case 'o':
698 case 'f':
699 case 'c':
701 break;
702 default:
703 result =
"<unknown_format>";
704 break;
705 }
706
707
710}
fl::string apply_width(const fl::string &str, const FormatSpec &spec, bool is_numeric=false) FL_NO_EXCEPT
fl::string to_hex(T value, bool uppercase=false, bool pad_to_width=false) FL_NO_EXCEPT
Convert an integer value to hexadecimal string representation.
expected< T, E > result
Alias for expected (Rust-style naming)