Forbid use of `std::time::Instant` on wasm

This commit is contained in:
Emil Ernerfeldt 2024-03-26 11:15:08 +01:00
parent a03604fce0
commit 8a10f81ca0
1 changed files with 1 additions and 0 deletions

View File

@ -38,6 +38,7 @@ disallowed-methods = [
disallowed-types = [
{ path = "instant::SystemTime", reason = "Known bugs. Use web-time." },
{ path = "std::thread::Builder", reason = "Cannot spawn threads on wasm" },
{ path = "std::time::Instant", reason = "Use web-time instead." },
# { path = "std::path::PathBuf", reason = "Can't read/write files on web" }, // TODO(emilk): consider banning Path on wasm
]