mirror of
https://github.com/shadps4-emu/shadPS4.git
synced 2025-05-23 03:45:00 +00:00
User-defined literals
This commit is contained in:
parent
441471370e
commit
c0c6024e2c
3 changed files with 9 additions and 3 deletions
|
@ -13,4 +13,10 @@ using u64 = unsigned long long;
|
|||
using f32 = float;
|
||||
using f64 = double;
|
||||
|
||||
#define PS4_SYSV_ABI __attribute__((sysv_abi))
|
||||
#define PS4_SYSV_ABI __attribute__((sysv_abi))
|
||||
|
||||
|
||||
// UDLs for memory size values
|
||||
constexpr u64 operator""_KB(u64 x) { return 1024ULL * x; }
|
||||
constexpr u64 operator""_MB(u64 x) { return 1024_KB * x; }
|
||||
constexpr u64 operator""_GB(u64 x) { return 1024_MB * x; }
|
Loading…
Add table
Add a link
Reference in a new issue