Commit 91a95682 authored by Christian Jullien's avatar Christian Jullien
Browse files

[macOS] Add VT_LDOUBLE special case for Rosetta to handle --cpu=x86_64.

parent 592cf7fb
......@@ -8093,6 +8093,11 @@ static void init_putv(init_params *p, CType *type, unsigned long c)
else if (sizeof(double) == LDOUBLE_SIZE)
memcpy(ptr, &vtop->c.ld, LDOUBLE_SIZE);
#if defined(TCC_TARGET_MACHO) && defined(TCC_TARGET_X86_64)
/* Special case for Rosetta to handle --cpu=x86_64 on macOS */
else if (sizeof(double) == sizeof(long double))
memcpy(ptr, &vtop->c.ld, sizeof(double));
tcc_error("can't cross compile long double constants");
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment