xtd 0.2.0
Loading...
Searching...
No Matches
literals.hpp
Go to the documentation of this file.
1
4#pragma once
5#include "time_span.hpp"
6#include "types.hpp"
7#include "string.hpp"
8#define __XTD_STD_INTERNAL__
10#undef __XTD_STD_INTERNAL__
11
13namespace xtd {
15 inline namespace literals {
26 xtd::byte operator""_b(long double n);
27
38 xtd::byte operator""_b(unsigned long long n);
39
50 xtd::byte operator""_b(const char* s, size_t n);
51
52#if defined(__xtd__cpp_lib_char8_t)
63 xtd::byte operator""_b(const char8* s, size_t n);
64#endif
65
76 xtd::byte operator""_b(const char16* s, size_t n);
77
88 xtd::byte operator""_b(const char32* s, size_t n);
89
100 xtd::byte operator""_b(const wchar* s, size_t n);
101
112 double operator""_d(long double n);
113
124 double operator""_d(unsigned long long n);
125
136 double operator""_d(const char* s, size_t n);
137
138#if defined(__xtd__cpp_lib_char8_t)
149 double operator""_d(const char8* s, size_t n);
150#endif
151
162 double operator""_d(const char16* s, size_t n);
163
174 double operator""_d(const char32* s, size_t n);
175
186 double operator""_d(const wchar* s, size_t n);
187
198 float operator""_f(long double n);
199
210 float operator""_f(unsigned long long n);
211
222 float operator""_f(const char* s, size_t n);
223
224#if defined(__xtd__cpp_lib_char8_t)
235 float operator""_f(const char8* s, size_t n);
236#endif
237
248 float operator""_f(const char16* s, size_t n);
249
260 float operator""_f(const char32* s, size_t n);
261
272 float operator""_f(const wchar* s, size_t n);
273
284 char32 operator""_c(char c);
285
296 char32 operator""_c(char16 c);
297
308 char32 operator""_c(char32 c);
309
320 char32 operator""_c(wchar c);
321
332 char32 operator""_c(unsigned long long c);
333
345 xtd::time_span operator""_h(unsigned long long s);
346
357 sbyte operator""_i8(long double n);
358
369 sbyte operator""_i8(unsigned long long n);
370
381 sbyte operator""_i8(const char* s, size_t n);
382
383#if defined(__xtd__cpp_lib_char8_t)
394 sbyte operator""_i8(const char8* s, size_t n);
395#endif
396
407 sbyte operator""_i8(const char16* s, size_t n);
408
419 sbyte operator""_i8(const char32* s, size_t n);
420
431 sbyte operator""_i8(const wchar* s, size_t n);
432
443 int16 operator""_i16(long double n);
444
455 int16 operator""_i16(unsigned long long n);
456
467 int16 operator""_i16(const char* s, size_t n);
468
469#if defined(__xtd__cpp_lib_char8_t)
480 int16 operator""_i16(const char8* s, size_t n);
481#endif
482
493 int16 operator""_i16(const char16* s, size_t n);
494
505 int16 operator""_i16(const char32* s, size_t n);
506
517 int16 operator""_i16(const wchar* s, size_t n);
518
529 int32 operator""_i32(long double n);
530
541 int32 operator""_i32(unsigned long long n);
542
553 int32 operator""_i32(const char* s, size_t n);
554
555#if defined(__xtd__cpp_lib_char8_t)
566 int32 operator""_i32(const char8* s, size_t n);
567#endif
568
579 int32 operator""_i32(const char16* s, size_t n);
580
591 int32 operator""_i32(const char32* s, size_t n);
592
603 int32 operator""_i32(const wchar* s, size_t n);
604
615 int64 operator""_i64(long double n);
616
627 int64 operator""_i64(unsigned long long n);
628
639 int64 operator""_i64(const char* s, size_t n);
640
641#if defined(__xtd__cpp_lib_char8_t)
652 int64 operator""_i64(const char8* s, size_t n);
653#endif
654
665 int64 operator""_i64(const char16* s, size_t n);
666
677 int64 operator""_i64(const char32* s, size_t n);
678
689 int64 operator""_i64(const wchar* s, size_t n);
690
702 xtd::time_span operator""_m(unsigned long long s);
703
715 xtd::time_span operator""_min(unsigned long long s);
716
728 xtd::time_span operator""_ms(unsigned long long s);
729
741 xtd::time_span operator""_ns(unsigned long long s);
742
754 xtd::string operator""_s(const char* s, size_t n);
755
756#if defined(__xtd__cpp_lib_char8_t)
768 xtd::string operator""_s(const char8* s, size_t n);
769#endif
770
782 xtd::string operator""_s(const char16* s, size_t n);
783
795 xtd::string operator""_s(const char32* s, size_t n);
796
808 xtd::string operator""_s(const wchar* s, size_t n);
809
821 xtd::time_span operator""_s(unsigned long long s);
822
834 xtd::string operator""_sb(unsigned long long s);
835
847 xtd::string operator""_sb2(unsigned long long s);
848
860 xtd::string operator""_sb4(unsigned long long s);
861
873 xtd::string operator""_sb8(unsigned long long s);
874
886 xtd::string operator""_sb16(unsigned long long s);
887
899 xtd::string operator""_sb32(unsigned long long s);
900
912 xtd::string operator""_sb64(unsigned long long s);
913
925 xtd::string operator""_sd(long double s);
926
938 xtd::string operator""_sd(unsigned long long s);
939
951 xtd::string operator""_sx(unsigned long long s);
952
964 xtd::string operator""_sx2(unsigned long long s);
965
977 xtd::string operator""_sx4(unsigned long long s);
978
990 xtd::string operator""_sx8(unsigned long long s);
991
1003 xtd::string operator""_sX(unsigned long long s);
1004
1016 xtd::string operator""_sX2(unsigned long long s);
1017
1029 xtd::string operator""_sX4(unsigned long long s);
1030
1042 xtd::string operator""_sX8(unsigned long long s);
1043
1054 sbyte operator""_s8(long double n);
1055
1066 sbyte operator""_s8(unsigned long long n);
1067
1078 sbyte operator""_s8(const char* s, size_t n);
1079
1080#if defined(__xtd__cpp_lib_char8_t)
1091 sbyte operator""_s8(const char8* s, size_t n);
1092#endif
1093
1104 sbyte operator""_s8(const char16* s, size_t n);
1105
1116 sbyte operator""_s8(const char32* s, size_t n);
1117
1128 sbyte operator""_s8(const wchar* s, size_t n);
1129
1140 int16 operator""_s16(long double n);
1141
1152 int16 operator""_s16(unsigned long long n);
1153
1164 int16 operator""_s16(const char* s, size_t n);
1165
1166#if defined(__xtd__cpp_lib_char8_t)
1177 int16 operator""_s16(const char8* s, size_t n);
1178#endif
1179
1190 int16 operator""_s16(const char16* s, size_t n);
1191
1202 int16 operator""_s16(const char32* s, size_t n);
1203
1214 int16 operator""_s16(const wchar* s, size_t n);
1215
1226 int32 operator""_s32(long double n);
1227
1238 int32 operator""_s32(unsigned long long n);
1239
1250 int32 operator""_s32(const char* s, size_t n);
1251
1252#if defined(__xtd__cpp_lib_char8_t)
1263 int32 operator""_s32(const char8* s, size_t n);
1264#endif
1265
1276 int32 operator""_s32(const char16* s, size_t n);
1277
1288 int32 operator""_s32(const char32* s, size_t n);
1289
1300 int32 operator""_s32(const wchar* s, size_t n);
1301
1312 int64 operator""_s64(long double n);
1313
1324 int64 operator""_s64(unsigned long long n);
1325
1336 int64 operator""_s64(const char* s, size_t n);
1337
1338#if defined(__xtd__cpp_lib_char8_t)
1349 int64 operator""_s64(const char8* s, size_t n);
1350#endif
1351
1362 int64 operator""_s64(const char16* s, size_t n);
1363
1374 int64 operator""_s64(const char32* s, size_t n);
1375
1386 int64 operator""_s64(const wchar* s, size_t n);
1387
1394 const char* operator""_t(const char* s, size_t n) noexcept;
1395
1396#if defined(__xtd__cpp_lib_char8_t)
1403 xtd::string operator""_t(const char8* s, size_t n) noexcept;
1404#endif
1405
1412 xtd::string operator""_t(const char16* s, size_t n) noexcept;
1413
1420 xtd::string operator""_t(const char32* s, size_t n) noexcept;
1421
1428 xtd::string operator""_t(const wchar* s, size_t n) noexcept;
1429
1441 xtd::time_span operator""_t(unsigned long long s);
1442
1453 xtd::byte operator""_u8(long double n);
1454
1465 xtd::byte operator""_u8(unsigned long long n);
1466
1477 xtd::byte operator""_u8(const char* s, size_t n);
1478
1479#if defined(__xtd__cpp_lib_char8_t)
1490 xtd::byte operator""_u8(const char8* s, size_t n);
1491#endif
1492
1503 xtd::byte operator""_u8(const char16* s, size_t n);
1504
1515 xtd::byte operator""_u8(const char32* s, size_t n);
1516
1527 xtd::byte operator""_u8(const wchar* s, size_t n);
1528
1539 uint16 operator""_u16(long double n);
1540
1551 uint16 operator""_u16(unsigned long long n);
1552
1563 uint16 operator""_u16(const char* s, size_t n);
1564
1565#if defined(__xtd__cpp_lib_char8_t)
1576 uint16 operator""_u16(const char8* s, size_t n);
1577#endif
1578
1589 uint16 operator""_u16(const char16* s, size_t n);
1590
1601 uint16 operator""_u16(const char32* s, size_t n);
1602
1613 uint16 operator""_u16(const wchar* s, size_t n);
1614
1625 uint32 operator""_u32(long double n);
1626
1637 uint32 operator""_u32(unsigned long long n);
1638
1649 uint32 operator""_u32(const char* s, size_t n);
1650
1651#if defined(__xtd__cpp_lib_char8_t)
1662 uint32 operator""_u32(const char8* s, size_t n);
1663#endif
1664
1675 uint32 operator""_u32(const char16* s, size_t n);
1676
1687 uint32 operator""_u32(const char32* s, size_t n);
1688
1699 uint32 operator""_u32(const wchar* s, size_t n);
1700
1711 uint64 operator""_u64(long double n);
1712
1723 uint64 operator""_u64(unsigned long long n);
1724
1735 uint64 operator""_u64(const char* s, size_t n);
1736
1737#if defined(__xtd__cpp_lib_char8_t)
1748 uint64 operator""_u64(const char8* s, size_t n);
1749#endif
1750
1761 uint64 operator""_u64(const char16* s, size_t n);
1762
1773 uint64 operator""_u64(const char32* s, size_t n);
1774
1785 uint64 operator""_u64(const wchar* s, size_t n);
1786
1798 xtd::time_span operator""_us(unsigned long long s);
1799 }
1800
1811 size_t operator""_uz(long double n);
1812
1823 size_t operator""_uz(unsigned long long n);
1824
1835 size_t operator""_uz(const char* s, size_t n);
1836
1837#if defined(__xtd__cpp_lib_char8_t)
1848 size_t operator""_uz(const char8* s, size_t n);
1849#endif
1850
1861 size_t operator""_uz(const char16* s, size_t n);
1862
1873 size_t operator""_uz(const char32* s, size_t n);
1874
1885 size_t operator""_uz(const wchar* s, size_t n);
1886
1897 size_t operator""_z(long double n);
1898
1909 size_t operator""_z(unsigned long long n);
1910
1921 size_t operator""_z(const char* s, size_t n);
1922
1923#if defined(__xtd__cpp_lib_char8_t)
1934 size_t operator""_z(const char8* s, size_t n);
1935#endif
1936
1947 size_t operator""_z(const char16* s, size_t n);
1948
1959 size_t operator""_z(const char32* s, size_t n);
1960
1971 size_t operator""_z(const wchar* s, size_t n);
1972}
Contains __xtd_std_version definitions.
Represents text as a sequence of character units.
Definition basic_string.hpp:79
int16_t int16
Represents a 16-bit signed integer.
Definition int16.hpp:23
char8_t char8
Represents a 8-bit unicode character.
Definition char8.hpp:27
wchar_t wchar
Represents a wide character.
Definition wchar.hpp:24
int32_t int32
Represents a 32-bit signed integer.
Definition int32.hpp:23
int64_t int64
Represents a 64-bit signed integer.
Definition int64.hpp:23
int8_t sbyte
Represents a 8-bit signed integer.
Definition sbyte.hpp:23
char16_t char16
Represents a 16-bit unicode character.
Definition char16.hpp:26
uint32_t uint32
Represents a 32-bit unsigned integer.
Definition uint32.hpp:23
char32_t char32
Represents a 32-bit unicode character.
Definition char32.hpp:26
uint64_t uint64
Represents a 64-bit unsigned integer.
Definition uint64.hpp:23
uint8_t byte
Represents a 8-bit unsigned integer.
Definition byte.hpp:23
uint16_t uint16
Represents a 16-bit unsigned integer.
Definition uint16.hpp:23
@ s
The S key.
@ c
The C key.
@ n
The N key.
The xtd namespace contains all fundamental classes to access Hardware, Os, System,...
Definition xtd_about_box.hpp:10
Contains xtd::string alias.
Represents a time interval.
Definition time_span.hpp:29
Contains xtd::time_span typedef.
Contains xtd fundamental types.