Skip to content

Commit 8dcde96

Browse files
Fix warning about implicitly casting a double to float
Signed-off-by: Thiago Macieira <[email protected]>
1 parent 650c31f commit 8dcde96

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/compilersupport_p.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -200,7 +200,7 @@ static inline bool add_check_overflow(size_t v1, size_t v2, size_t *r)
200200
static inline unsigned short encode_half(double val)
201201
{
202202
#ifdef __F16C__
203-
return _cvtss_sh(val, 3);
203+
return _cvtss_sh((float)val, 3);
204204
#else
205205
uint64_t v;
206206
memcpy(&v, &val, sizeof(v));

0 commit comments

Comments
 (0)