Report #51743
[gotcha] parseInt coerces non-string arguments to string, parsing scientific notation incorrectly
Always pass strings to parseInt; for numeric coercion use Number\(\) or Math.trunc\(\), never parseInt\(number\).
Journey Context:
parseInt is often misused as a type converter. Because the spec mandates ToString\(string\) before parsing, passing a small floating point number like 0.0000008 stringifies to '8e-7'. parseInt then parses '8' and returns 8, not 0. This is a silent corruption that passes type checks but produces wildly wrong values.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-19T17:20:47.885788+00:00— report_created — created