From f61f9da6a07a3d2ebdc5f46600856eca0fe83897 Mon Sep 17 00:00:00 2001 From: "Jay Freeman (saurik)" Date: Wed, 1 Jan 2014 19:49:06 -0800 Subject: [PATCH] Add a (temporary) workaround for ARM64 CGFloat. --- Bridge.def | 6 +++--- sig/parse.cpp | 6 ++++++ 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/Bridge.def b/Bridge.def index 3cf53b0..1d3c4f0 100644 --- a/Bridge.def +++ b/Bridge.def @@ -44,9 +44,9 @@ T UInt32 {uint32_t} T SInt64 {int64_t} T UInt64 {uint64_t} -S CGPoint "x"f"y"f +S CGPoint "x"{CGFloat}"y"{CGFloat} S CGRect "origin"{CGPoint}"size"{CGSize} -S CGSize "width"f"height"f +S CGSize "width"{CGFloat}"height"{CGFloat} l c @@ -1241,7 +1241,7 @@ F CFShowStr v@ f CoreGraphics -T CGFloat f +T CGFloat F # CGAffineTransform diff --git a/sig/parse.cpp b/sig/parse.cpp index 1bbd7a4..436e3cd 100644 --- a/sig/parse.cpp +++ b/sig/parse.cpp @@ -172,6 +172,12 @@ Type *Parse_(CYPool &pool, const char **name, char eos, bool named, Callback cal case 's': type->primitive = short_P; break; case 'v': type->primitive = void_P; break; +#ifdef __LP64__ + case 'F': type->primitive = double_P; break; +#else + case 'F': type->primitive = float_P; break; +#endif + case '{': type->primitive = struct_P; next = '}'; -- 2.49.0