mirror of
https://github.com/xomboverlord/ldc.git
synced 2026-09-22 21:30:18 +02:00
Use %La to hex-format a real instead of pretending it's an integer.
This commit is contained in:
+1
-3
@@ -11,7 +11,6 @@
|
|||||||
#include <fstream>
|
#include <fstream>
|
||||||
|
|
||||||
#include "gen/llvm.h"
|
#include "gen/llvm.h"
|
||||||
#include "llvm/Support/DataTypes.h"
|
|
||||||
|
|
||||||
#include "attrib.h"
|
#include "attrib.h"
|
||||||
#include "init.h"
|
#include "init.h"
|
||||||
@@ -314,8 +313,7 @@ DValue* RealExp::toElem(IRState* p)
|
|||||||
|
|
||||||
LLConstant* RealExp::toConstElem(IRState* p)
|
LLConstant* RealExp::toConstElem(IRState* p)
|
||||||
{
|
{
|
||||||
Logger::print("RealExp::toConstElem: %s @ %s | %LX\n", toChars(), type->toChars(),
|
Logger::print("RealExp::toConstElem: %s @ %s | %La\n", toChars(), type->toChars(), value);
|
||||||
UINT64_C(0xFFFFFFFFFF) & *(long long unsigned*)&value);
|
|
||||||
LOG_SCOPE;
|
LOG_SCOPE;
|
||||||
Type* t = type->toBasetype();
|
Type* t = type->toBasetype();
|
||||||
return DtoConstFP(t, value);
|
return DtoConstFP(t, value);
|
||||||
|
|||||||
Reference in New Issue
Block a user