From b5393c66a9dc31a3dea91f566ecc8306e5aba4ba Mon Sep 17 00:00:00 2001 From: Doehyun Baek Date: Mon, 26 Aug 2024 16:11:17 +0900 Subject: [PATCH] filter out pass-big-number for now --- crates/replay_gen/src/trace.rs | 6 ++++++ src/filter.ts | 1 + 2 files changed, 7 insertions(+) diff --git a/crates/replay_gen/src/trace.rs b/crates/replay_gen/src/trace.rs index 16ee452..d56881e 100644 --- a/crates/replay_gen/src/trace.rs +++ b/crates/replay_gen/src/trace.rs @@ -205,6 +205,12 @@ fn test_parse_number() { // problematic case reading the trace generateed by js let s = "0.7614822387695312"; assert_ne!(s, parse_number(s).unwrap().to_js()); + + // problematic cases where the number is too big or too small to be handled by f64 + let small_number = "-9223372036854775808"; + let big_number = "9223372036854775807"; + assert_ne!(small_number, parse_number(small_number).unwrap().to_js()); + assert_ne!(big_number, parse_number(big_number).unwrap().to_js()); } #[derive(Debug)] diff --git a/src/filter.ts b/src/filter.ts index c7a8cfb..0ebdd57 100644 --- a/src/filter.ts +++ b/src/filter.ts @@ -15,6 +15,7 @@ export const filter = { 'call-exp-after-import-call-table-get', // unknown function wasabi 'test04', // duplicate func export 'rust-game-of-life', // fail only at CI + "pass-big-number" // better handling of i64 value is needed ], proxy: [ // TODO: fix these regressions