mirror of
https://github.com/servo/servo.git
synced 2025-07-23 07:13:52 +01:00
remove usage of legacy numeric operations in script (#33095)
These operations are deprecated and might be removed in a future rust version. Clippy is also complaining about them. Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>
This commit is contained in:
parent
09cac6430b
commit
f0045a7686
4 changed files with 8 additions and 11 deletions
|
@ -630,7 +630,7 @@ unsafe fn new_rt_and_cx_with_parent(
|
|||
if pref!(js.baseline_jit.unsafe_eager_compilation.enabled) {
|
||||
0
|
||||
} else {
|
||||
u32::max_value()
|
||||
u32::MAX
|
||||
},
|
||||
);
|
||||
JS_SetGlobalJitCompilerOption(
|
||||
|
@ -639,7 +639,7 @@ unsafe fn new_rt_and_cx_with_parent(
|
|||
if pref!(js.ion.unsafe_eager_compilation.enabled) {
|
||||
0
|
||||
} else {
|
||||
u32::max_value()
|
||||
u32::MAX
|
||||
},
|
||||
);
|
||||
// TODO: handle js.discard_system_source.enabled
|
||||
|
@ -652,7 +652,7 @@ unsafe fn new_rt_and_cx_with_parent(
|
|||
JSGCParamKey::JSGC_MAX_BYTES,
|
||||
in_range(pref!(js.mem.max), 1, 0x100)
|
||||
.map(|val| (val * 1024 * 1024) as u32)
|
||||
.unwrap_or(u32::max_value()),
|
||||
.unwrap_or(u32::MAX),
|
||||
);
|
||||
// NOTE: This is disabled above, so enabling it here will do nothing for now.
|
||||
JS_SetGCParameter(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue