mirror of
https://github.com/Mercury-Language/mercury.git
synced 2025-12-16 22:35:41 +00:00
Fix bug reported by Dylan: float constants are boxed and thus
code_exprn.m: Fix bug reported by Dylan: float constants are boxed and thus cannot be considered constant.
This commit is contained in:
@@ -711,6 +711,13 @@ code_exprn__expr_is_constant(const(Const), _Vars,
|
||||
AsmLabels = yes
|
||||
)
|
||||
)
|
||||
;
|
||||
Const = float_const(_)
|
||||
->
|
||||
% Floating point constants are currently boxed by default;
|
||||
% the memory allocation means that they are not constant
|
||||
% expressions.
|
||||
fail
|
||||
;
|
||||
true
|
||||
),
|
||||
|
||||
Reference in New Issue
Block a user