28#ifndef DOUBLE_CONVERSION_UTILS_H_
29#define DOUBLE_CONVERSION_UTILS_H_
38#if __cplusplus >= 201103L
39#define DOUBLE_CONVERSION_NULLPTR nullptr
41#define DOUBLE_CONVERSION_NULLPTR NULL
45#ifndef DOUBLE_CONVERSION_ASSERT
46#define DOUBLE_CONVERSION_ASSERT(condition) \
49#if defined(DOUBLE_CONVERSION_NON_PREFIXED_MACROS) && !defined(ASSERT)
50#define ASSERT DOUBLE_CONVERSION_ASSERT
53#ifndef DOUBLE_CONVERSION_UNIMPLEMENTED
54#define DOUBLE_CONVERSION_UNIMPLEMENTED() (abort())
56#if defined(DOUBLE_CONVERSION_NON_PREFIXED_MACROS) && !defined(UNIMPLEMENTED)
57#define UNIMPLEMENTED DOUBLE_CONVERSION_UNIMPLEMENTED
60#ifndef DOUBLE_CONVERSION_NO_RETURN
62#define DOUBLE_CONVERSION_NO_RETURN __declspec(noreturn)
64#define DOUBLE_CONVERSION_NO_RETURN __attribute__((noreturn))
67#if defined(DOUBLE_CONVERSION_NON_PREFIXED_MACROS) && !defined(NO_RETURN)
68#define NO_RETURN DOUBLE_CONVERSION_NO_RETURN
71#ifndef DOUBLE_CONVERSION_UNREACHABLE
74inline void abort_noreturn() { abort(); }
75#define DOUBLE_CONVERSION_UNREACHABLE() (abort_noreturn())
77#define DOUBLE_CONVERSION_UNREACHABLE() (abort())
80#if defined(DOUBLE_CONVERSION_NON_PREFIXED_MACROS) && !defined(UNREACHABLE)
81#define UNREACHABLE DOUBLE_CONVERSION_UNREACHABLE
87# define DOUBLE_CONVERSION_HAS_ATTRIBUTE(x) __has_attribute(x)
89# define DOUBLE_CONVERSION_HAS_ATTRIBUTE(x) 0
92#ifndef DOUBLE_CONVERSION_UNUSED
93#if DOUBLE_CONVERSION_HAS_ATTRIBUTE(unused)
94#define DOUBLE_CONVERSION_UNUSED __attribute__((unused))
96#define DOUBLE_CONVERSION_UNUSED
99#if defined(DOUBLE_CONVERSION_NON_PREFIXED_MACROS) && !defined(UNUSED)
100#define UNUSED DOUBLE_CONVERSION_UNUSED
103#if DOUBLE_CONVERSION_HAS_ATTRIBUTE(uninitialized)
104#define DOUBLE_CONVERSION_STACK_UNINITIALIZED __attribute__((uninitialized))
106#define DOUBLE_CONVERSION_STACK_UNINITIALIZED
108#if defined(DOUBLE_CONVERSION_NON_PREFIXED_MACROS) && !defined(STACK_UNINITIALIZED)
109#define STACK_UNINITIALIZED DOUBLE_CONVERSION_STACK_UNINITIALIZED
138#if defined(_M_X64) || defined(__x86_64__) || \
139 defined(__ARMEL__) || defined(__avr32__) || defined(_M_ARM) || defined(_M_ARM64) || \
140 defined(__hppa__) || defined(__ia64__) || \
141 defined(__mips__) || \
142 defined(__loongarch__) || \
143 defined(__nios2__) || defined(__ghs) || \
144 defined(__powerpc__) || defined(__ppc__) || defined(__ppc64__) || \
145 defined(_POWER) || defined(_ARCH_PPC) || defined(_ARCH_PPC64) || \
146 defined(__sparc__) || defined(__sparc) || defined(__s390__) || \
147 defined(__SH4__) || defined(__alpha__) || \
148 defined(_MIPS_ARCH_MIPS32R2) || defined(__ARMEB__) ||\
149 defined(__AARCH64EL__) || defined(__aarch64__) || defined(__AARCH64EB__) || \
150 defined(__riscv) || defined(__e2k__) || \
151 defined(__or1k__) || defined(__arc__) || defined(__ARC64__) || \
152 defined(__microblaze__) || defined(__XTENSA__) || \
153 defined(__EMSCRIPTEN__) || defined(__wasm32__)
154#define DOUBLE_CONVERSION_CORRECT_DOUBLE_OPERATIONS 1
155#elif defined(__mc68000__) || \
156 defined(__pnacl__) || defined(__native_client__)
157#undef DOUBLE_CONVERSION_CORRECT_DOUBLE_OPERATIONS
158#elif defined(_M_IX86) || defined(__i386__) || defined(__i386)
161#define DOUBLE_CONVERSION_CORRECT_DOUBLE_OPERATIONS 1
163#undef DOUBLE_CONVERSION_CORRECT_DOUBLE_OPERATIONS
166#error Target architecture was not detected as supported by Double-Conversion.
168#if defined(DOUBLE_CONVERSION_NON_PREFIXED_MACROS) && !defined(CORRECT_DOUBLE_OPERATIONS)
169#define CORRECT_DOUBLE_OPERATIONS DOUBLE_CONVERSION_CORRECT_DOUBLE_OPERATIONS
172#if defined(_WIN32) && !defined(__MINGW32__)
174typedef signed char int8_t;
175typedef unsigned char uint8_t;
176typedef short int16_t;
177typedef unsigned short uint16_t;
179typedef unsigned int uint32_t;
180typedef __int64 int64_t;
181typedef unsigned __int64 uint64_t;
195#define DOUBLE_CONVERSION_UINT64_2PART_C(a, b) (((static_cast<uint64_t>(a) << 32) + 0x##b##u))
196#if defined(DOUBLE_CONVERSION_NON_PREFIXED_MACROS) && !defined(UINT64_2PART_C)
197#define UINT64_2PART_C DOUBLE_CONVERSION_UINT64_2PART_C
204#ifndef DOUBLE_CONVERSION_ARRAY_SIZE
205#define DOUBLE_CONVERSION_ARRAY_SIZE(a) \
206 ((sizeof(a) / sizeof(*(a))) / \
207 static_cast<size_t>(!(sizeof(a) % sizeof(*(a)))))
209#if defined(DOUBLE_CONVERSION_NON_PREFIXED_MACROS) && !defined(ARRAY_SIZE)
210#define ARRAY_SIZE DOUBLE_CONVERSION_ARRAY_SIZE
215#ifndef DOUBLE_CONVERSION_DISALLOW_COPY_AND_ASSIGN
216#define DOUBLE_CONVERSION_DISALLOW_COPY_AND_ASSIGN(TypeName) \
217 TypeName(const TypeName&); \
218 void operator=(const TypeName&)
220#if defined(DOUBLE_CONVERSION_NON_PREFIXED_MACROS) && !defined(DC_DISALLOW_COPY_AND_ASSIGN)
221#define DC_DISALLOW_COPY_AND_ASSIGN DOUBLE_CONVERSION_DISALLOW_COPY_AND_ASSIGN
230#ifndef DOUBLE_CONVERSION_DISALLOW_IMPLICIT_CONSTRUCTORS
231#define DOUBLE_CONVERSION_DISALLOW_IMPLICIT_CONSTRUCTORS(TypeName) \
233 DOUBLE_CONVERSION_DISALLOW_COPY_AND_ASSIGN(TypeName)
235#if defined(DOUBLE_CONVERSION_NON_PREFIXED_MACROS) && !defined(DC_DISALLOW_IMPLICIT_CONSTRUCTORS)
236#define DC_DISALLOW_IMPLICIT_CONSTRUCTORS DOUBLE_CONVERSION_DISALLOW_IMPLICIT_CONSTRUCTORS
242 size_t length = strlen(
string);
244 return static_cast<int>(
length);
277 return start_[index];
282 T&
last() {
return start_[length_ - 1]; }
322 buffer_[position_++] = c;
336 memmove(&buffer_[position_],
s,
static_cast<size_t>(n));
352 buffer_[position_] =
'\0';
358 return buffer_.
start();
365 bool is_finalized()
const {
return position_ < 0; }
367 DOUBLE_CONVERSION_DISALLOW_IMPLICIT_CONSTRUCTORS(
StringBuilder);
394template <
class Dest,
class Source>
398#if __cplusplus >= 201103L
399 static_assert(
sizeof(Dest) ==
sizeof(Source),
400 "source and destination size mismatch");
403 typedef char VerifySizesAreEqual[
sizeof(Dest) ==
sizeof(Source) ? 1 : -1];
411template <
class Dest,
class Source>
413 return BitCast<Dest>(
reinterpret_cast<uintptr_t
>(
source));
static uint32_t buffer_size(uint32_t offset, uint32_t maxAlignment)
void AddCharacter(char c)
void AddSubstring(const char *s, int n)
StringBuilder(char *buffer, int buffer_size)
void AddPadding(char c, int count)
void AddString(const char *s)
T & operator[](int index) const
Vector< T > SubVector(int from, int to)
Dest BitCast(const Source &source)
int StrLength(const char *string)
DEF_SWITCHES_START aot vmservice shared library Name of the *so containing AOT compiled Dart assets for launching the service isolate vm snapshot The VM snapshot data that will be memory mapped as read only SnapshotAssetPath must be present isolate snapshot The isolate snapshot data that will be memory mapped as read only SnapshotAssetPath must be present cache dir Path to the cache directory This is different from the persistent_cache_path in embedder which is used for Skia shader cache icu native lib Path to the library file that exports the ICU data vm service The hostname IP address on which the Dart VM Service should be served If not defaults to or::depending on whether ipv6 is specified vm service A custom Dart VM Service port The default is to pick a randomly available open port disable vm Disable the Dart VM Service The Dart VM Service is never available in release mode disable vm service Disable mDNS Dart VM Service publication Bind to the IPv6 localhost address for the Dart VM Service Ignored if vm service host is set endless trace buffer
std::shared_ptr< const fml::Mapping > data
#define DOUBLE_CONVERSION_NULLPTR
#define DOUBLE_CONVERSION_UNUSED
#define DOUBLE_CONVERSION_ASSERT(condition)
#define DOUBLE_CONVERSION_NO_RETURN