Remove dead code from the bun_runtime re-export hubs, bun_core, bun_css, bun_install, bun_bundler, the FFI crates, and the error-code table - #39319
Conversation
…ss, bun_install, bun_bundler, the FFI crates, and the error-code table
Deletes src/jsc/generated_classes_list.rs (an alias namespace with no
reader), the unused aliases in bun_runtime's api.rs / webcore.rs / bake /
server / cli re-export hubs, a handful of never-constructed enum variants
(streams::Writable::{TemporaryAndDone, IntoArray, IntoArrayAndDone},
WritableFuture::Handler, DrainResult::Empty, Source::Direct,
pretty_format Tag::ArrayBuffer, shell IoKind::Stdin, fs watcher
Event::Close, CalendarError::OutOfMemory, thumbhash
DecodeError::OutOfMemory), the never-called ServerLike consts / vm_mut and
ResponseLike::upgrade, leftover re-exports and helpers in bun_core,
bun_css, bun_install, bun_bundler, bun_collections, bun_sql_jsc and
bun_jsc, two FFI declarations with no caller (SetFileTime,
lsquic_conn_n_pending_streams), and 17 error codes nothing produces.
Each Rust item was reported unused by rustc with the crate's pub items
demoted to pub(crate), on the linux, windows and darwin targets; verified
with bun bd, rust:check-all, the affected test files, and a source lint
pinning the removed symbols.
|
Warning Review limit reached
Next review available in: 8 minutes Limit details: You’ve used all 5 included reviews currently available under your plan. Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available. How can I continue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: ASSERTIVE Plan: Pro Run ID: 📒 Files selected for processing (54)
Comment |
|
Updated 12:54 AM PT - Aug 16th, 2026
✅ @robobun, your commit fc4da40af6c62d0ca2fe32d8e1ab9c19169252af passed in 🧪 To try this PR locally: bunx bun-pr 39319That installs a local version of the PR into your bun-39319 --bun |
|
Status: ready for review (review feedback addressed, waiting on CI).
|
…mut and bake::production::EntryPointMap
|
Addressed the review in 8b2eb56 and fc4da40:
No code changes beyond comments since the first push. |
There was a problem hiding this comment.
Re-reviewed after 8b2eb56 and fc4da40 — no new issues found. I've verified the author's rebuttal on the ServerInitContext finding: AnyRoute is pub in server/mod.rs:148 and its inherent pub fn from_js (server_body.rs:759) takes &mut ServerInitContext, so rustc treats the struct as reachable and unreachable_pub does not fire; that finding was a false positive on my part. The two SAFETY-comment and doc-comment nits are fixed.
Given the breadth (54 files across ~10 crates, match-arm removals for never-constructed variants, 17 error-code table entries, and the generated_classes_list.rs deletion whose correctness rests on the codegen resolver), a human sanity pass is still worthwhile before merge.
Also checked: the new source-lint's /^\s+fn vm_mut\(/m check does not match the surviving inherent pub(crate) fn vm_mut at mod.rs:472, and the css/lib.rs ↔ css_parser.rs IdentFns/CustomIdentFns/DashedIdentFns re-shuffle keeps every previously-used path resolvable.
Extended reasoning...
Overview
This PR removes ~427 lines of dead code across 54 files: unused pub use re-exports in bun_runtime's hub modules (api.rs, webcore.rs, bake/mod.rs, etc.), the entire generated_classes_list.rs alias namespace, never-constructed enum variants and their match arms (DrainResult::Empty, ReadableStream::Source::Direct, Writable::{TemporaryAndDone,IntoArray,IntoArrayAndDone}, IoKind::Stdin, Event::Close, Tag::ArrayBuffer, two OutOfMemory error variants), never-called trait items (ServerLike::{SSL_ENABLED,DEBUG_MODE,vm_mut}, ResponseLike::upgrade), 17 unused error codes from ErrorCode.ts, two FFI declarations, and assorted crate-root re-exports in bun_core/bun_css/bun_install/bun_bundler/bun_collections/bun_sql_jsc. Seven items were demoted pub → pub(crate) to satisfy unreachable_pub = deny. A 201-line source-lint test pins the deletions.
Follow-up on prior review
My previous run flagged three items. The two 🟡 nits (SAFETY comments citing the removed ServerLike::vm_mut, and a stale EntryPointMap doc sentence) were fixed in 8b2eb56. The 🔴 ServerInitContext/unreachable_pub finding was rebutted by the author, and I have now verified the rebuttal is correct: AnyRoute is a pub enum in the pub server module, and impl AnyRoute { pub fn from_js(..., init_ctx: &mut ServerInitContext, ...) } at server_body.rs:759 makes ServerInitContext reachable through a public interface, so rustc does not emit unreachable_pub. Demoting it would instead trip private_interfaces. The author also confirmed bun bd and rust:check-all pass on all 12 targets. That thread should be considered resolved. The comment-cop hits on ByteStream.rs/FormData.rs were addressed in fc4da40 (comments trimmed/removed).
Security risks
None identified. This is pure deletion of unreferenced Rust items, re-exports, and error-code table entries. No auth, crypto, permission, or input-validation logic is touched. The removed error codes have no producers (verified per PR description via grep across $ERR_X( in src/js, ErrorCode::ERR_X in C++, ErrorCode::X in Rust).
Level of scrutiny
Medium-high. While each individual removal is mechanical, the aggregate is large and the correctness of several removals depends on non-local facts: (a) that generate-classes.ts truly does not read generated_classes_list.rs (author reports regenerated generated_classes.rs is byte-identical), (b) that no macro-expanded or cfg-gated code constructs the removed enum variants (author checked all three target OSes via rustc dead-code analysis after temporarily demoting pub → pub(crate)), and (c) that the 17 error codes have no dynamic producers. The methodology is sound and the compile-on-12-targets verification catches (b), but (a) and (c) rest on grep/byte-diff evidence a human should spot-check.
Other factors
- The PR description is exceptionally thorough, including a per-item rationale and an explicit list of items left alone because open PRs claim them.
- The source-lint test correctly scopes its regexes (verified
/^\s+fn vm_mut\(/mdoes not match the surviving inherent method). - The
css/lib.rschange is a re-shuffle rather than pure deletion (moves which module re-exportsIdentFnsvsCustomIdentFns/DashedIdentFns), but the net public surface is a strict subset of before. - CI build #99231 was still in progress at the time of the last status comment.
- 24 other dead-code PRs are open per the description; a maintainer should confirm this one's non-overlap claim holds against whatever has merged since.
|
For whoever does the sanity pass, the two points above that rest on non-compiler evidence are quick to reproduce:
All review threads are resolved; CI for fc4da40 is at 178/179 jobs passed with nothing failed so far. |
… and misc crates (#39574) ### Problem - `src/jsc/bindings/libuv/` is only on the include path for non-Windows builds (`scripts/build/flags.ts`, "libuv stubs for unix"). `uv/win.h` (703 lines) and `uv/tree.h` (512 lines, included only by `win.h`) are never reached. - `uv/sunos.h`, `uv/os390.h`, `uv/aix.h` and `uv/posix.h` are selected by `uv/unix.h` only on Solaris, z/OS, AIX, IBM i, Cygwin, Haiku, QNX and Hurd. Bun builds for linux, macOS and FreeBSD. - `packages/bun-error` is embedded in the dev error page (`src/runtime/server/dev-error-page.html`). The page calls the function behind `Symbol.for("Bun__renderFallbackError")` and nothing else. `renderRuntimeError`, the abort state `dismissError` kept for it, and the two modules only it imported (`sourcemap.ts`, `stack-trace-parser.ts`) have no callers. #37081 lists this path as a follow-up. - `bun_zlib_sys::posix` and `bun_zlib_sys::win32` declare zlib functions that nothing calls. `bun_zlib` declares its own. The only use of the two modules was as re-exports of the types in `shared.rs`. - A set of `pub` items in other crates has no user in any crate. rustc cannot report them because `pub` items count as used. ### Fix - Delete the six libuv headers. `uv.h` now includes `uv/unix.h` directly. `uv/unix.h` keeps the linux, darwin and BSD branches. `uv-posix-polyfills.c` drops the commented-out copies of the removed branches. - Delete `renderRuntimeError`, `sourcemap.ts` and `stack-trace-parser.ts`. `dismissError` keeps the part that removes the overlay. `runtime-error.ts` stays (it has a test). - Delete `bun_zlib_sys/posix.rs` and `win32.rs`. `bun_zlib` imports the types from `bun_zlib_sys::shared`, which is where the removed modules took them from. - Delete the unused Rust items listed below, plus the trait implementations and imports that only they needed. Verification: - Every Rust item was found by making the unexported items crate-private and compiling the workspace. An item is deleted only if rustc reports it dead on x86_64 linux (dev, release, and with the `bun_debug` and `bun_asan` cfgs), aarch64 linux, x86_64 musl, x86_64 Windows and aarch64 macOS. - Each removed name was also searched in `src/codegen/`, the `*.classes.ts` files, `src/js/` and the C++ bindings. Items that a codegen template can emit were kept. - `bun run rust:check-all`: 12 of 12 targets pass. `cargo check --workspace --all-targets` passes (benches and unit tests still compile). `cargo check -p bun_shim_impl --features shim_standalone` for the Windows target passes. - `bun bd` builds. The build recompiles `uv-posix-stubs.c` and `uv-posix-polyfills.c` against the trimmed `uv.h`, and rebuilds the bun-error bundle, which no longer exports `renderRuntimeError`. - New test in `test/js/bun/http/serve.test.ts`: it takes the bun-error bundle out of a real 500 page, evaluates it outside a browser, and checks that the bundle registers the renderer and that `dismissError` is a no-op when nothing is rendered. This is the surface the `packages/bun-error` change touches. - `bun bd test` passes for `test/js/bun/http/serve.test.ts -t "dev error page"` (including the new test), `test/js/bun/runtime-error.test.ts`, `test/js/bun/util/{zstd,arraybuffersink,filesink}.test.ts`, `test/js/node/zlib/deflate-streaming.test.ts`, `test/js/web/encoding/text-{encoder,decoder}.test.*`, `test/js/workerd/html-rewriter.test.js`, `test/js/bun/css/nth-anplusb-ident.test.ts`, `test/js/web/fetch/blob.test.ts` and `test/internal/source-lints/dead-code-escapes.test.ts`. - `cargo fmt --check`, clang-format on the touched C file and prettier on the touched TypeScript files pass. <details> <summary>Removed Rust items</summary> - `bun_zlib_sys`: modules `posix` and `win32` (`struct_gz_header_s`, `gz_header`, `gz_headerp`, `in_func`, `out_func`, and the `deflate*`, `inflate*`, `compress*`, `uncompress`, `adler32`, `crc32`, `zlibVersion` declarations), `shared::voidpf`. - `bun_zlib`: declarations `compress`, `compressBound`, `uncompress`, and the `internal` module that selected between the two removed modules. - `bun_zstd`: `decompress` (every caller uses `decompress_append`). - `bun_libdeflate_sys`: `libdeflate_deflate_decompress` (the `_ex` variant is the one in use). - `bun_mimalloc_sys`: `mi_strdup`, `mi_heap_collect`, `mi_thread_set_in_threadpool`. - `bun_cares_sys`: `ares_strerror`. - `bun_windows_sys`: `SetHandleInformation`, `closesocket`. - `bun_alloc`: `default_alloc::calloc`. - `bun_core`: `GenericIndexInt::from_usize` and its macro-generated implementations. - `bun_css`: the four deprecated `to_css` methods on `GenericSelectorList`, `GenericSelector`, `GenericComponent` and `Combinator`. Their bodies were `unreachable!()`; the serializer functions replaced them. - `bun_runtime`: `JsSinkType::done` and its six overrides, `FileCloser::update` and its implementations, `ReadableStream::to_js`, `node_fs::Null::to_js`. </details> <details> <summary>Overlap with open pull requests</summary> The deletions here were checked against the open dead-code pull requests (#35437, #35775, #35880, #36115, #36237, #37012, #37149, #37181, #37208, #37301, #37454, #37659, #37788, #38005, #38900, #39319, #39561) and against #38958 and #35075. Nothing deleted here is deleted by any of them. Candidates they already cover were left out: `src/jsc/bindgen.rs` (#37149), the dead `pub use` re-exports (#39319), the simdutf big-endian and UTF-32 wrappers (#38958), and the items named in the skip lists of the others. Some files here (`bun_alloc/lib.rs`, `bun_core/util.rs`, `libdeflate.rs`, `mimalloc.rs`, `node_fs.rs`, `Blob.rs`, `FileSink.rs`, `ReadableStream.rs`, `streams.rs`, `windows_sys/externs.rs`) are also touched by open pull requests in different hunks. #36437 edits `packages/bun-error` from a base that predates #37081; it changes one import line in `stack-trace-parser.ts` and keeps `renderRuntimeError`, so it does not overlap with this deletion but will need a rebase. </details> <details> <summary>Found but not deleted (judgment calls for a maintainer)</summary> - `packages/bun-inspector-protocol/src/protocol/v8/` (about 32,600 lines): not exported by the package index since 2023 and regenerated only with the opt-in `--v8` flag of `scripts/generate-protocol.ts`. #39110 kept the flag, so this needs a decision. - `packages/h3blast` (1,468 lines) and `packages/bun-build-mdx-rs` (558 lines): nothing in the repository references them. They may be kept on purpose as a load generator and a proof of concept. - `packages/bun-error/runtime-error.ts` is unused by the page but covered by `test/js/bun/runtime-error.test.ts`. The four images in `packages/bun-error/img/` are referenced only by the source glob in `scripts/glob-sources.ts`. - `HotReloadTaskView` in `src/jsc/hot_reloader.rs`: both `reload` implementations ignore the task, and `VirtualMachine::reload` ignores its `Option<HotReloadTask>` argument. Removing the plumbing is a small refactor rather than a deletion. - `react_compiler/compile_result.rs` has constructors and fields with no users, but the file says the types are waiting to be wired up. - The streams-era private globals in `BunBuiltinNames.h` (`makeGetterTypeError`, `makeDOMException`, `addAbortAlgorithmToSignal`, `removeAbortAlgorithmFromSignal`, `isAbortSignal`, `createUninitializedArrayBuffer`, about 100 lines of `ZigGlobalObject.cpp`) have no JS callers. Both files are being edited by several open dead-code pull requests, so they were left for a later run. </details> ### Background - rustc's `dead_code` lint treats every `pub` item in a library crate as used, because another crate could import it. In this workspace every crate is an implementation detail of one binary, so a `pub` item with no importer in any crate is dead in the same sense as a private one. Making such items crate-private for one compile lets rustc report the ones with no users at all. The visibility changes themselves are not part of this pull request. - On POSIX, bun does not link libuv. Node-API addons that reference libuv symbols get `uv-posix-stubs.c` and `uv-posix-polyfills*.c`, which are compiled against the copied headers in `src/jsc/bindings/libuv/`. On Windows the real libuv is linked and that directory is not used. - `JsSinkType` is the Rust trait behind the native sink classes (`FileSink`, `ArrayBufferSink`, the HTTP response sinks). Its methods are called from the shared sink glue in `Sink.rs`; `done` was declared there but the glue never called it. <!-- robobun:evidence:begin --> --- **no test proof** · iteration 1 · Platform-specific test(s) that do not run on this machine. Deferring to CI, which covers all platforms: test/js/bun/http/serve.test.ts <!-- robobun:evidence:end -->
|
Closing as stale: this has merge conflicts with main. If the dead code is still present, please open a fresh PR against current main. |
|
Reopened against current main as #39582 (same deletions, rebased; one conflict in |
Removes 427 lines that nothing references (44 lines of reflowed import groups, two blank lines that keep rustfmt's module groups where they were, and visibility adjustments added, plus a 201-line source lint pinning the removed symbols), mostly from
bun_runtime's re-export hubs, with leftovers inbun_core,bun_css,bun_install,bun_bundler,bun_collections,bun_sql_jsc,bun_jsc, the FFI declaration crates and the node error-code table. No behavior change.This run is small on purpose: 24 dead-code PRs are already open, and everything they delete was left alone (checked line by line against their diffs; see "Left alone" below). What is here is the residue those PRs do not cover.
Problem
bun_runtimere-export hubs (about 200 lines)src/jsc/generated_classes_list.rs(116 lines), mounted asbun_runtime::GeneratedClassesList, was a flat alias namespace with no reader:generate-classes.tsresolves each.classes.tsclass to its Rust type by walking the crate's ownpub mod/pub usetree (rustModuleResolver), and the regeneratedgenerated_classes.rsis byte-identical without the file.bun_runtimeis also the only crate that can see its own re-export hubs (nothing butbun_bindepends on it, andbun_binonly callsCli::start), so a hub entry rustc reports unused is unused everywhere.api.rsstill mirrored the oldbun.api.*Zig namespace: 36 aliases (Image,Shell,Timer,Archive,Glob,HTMLRewriter,NativeZlib,Valkey,MySQL,Postgres,FFIObject,SocketHandlers,x509, the 18process::*names other thanRusage, the five PTY types underbun::terminal,bun::H2FrameParser,posix_spawn,bun_spawn as spawn, ...) that no code and no generated code names.TCPSocket/TLSSocketstay: rustc reported them unused on linux, butsocket/WindowsNamedPipeContext.rsimports them throughapi.bun.js.rs(pub use crate::{api, webcore}),webcore.rs(the five sink re-exports,form_data::{AsyncFormData, FormData}, and thewebcore::jsc::codegenforwarding module whose doc comment says it exists for call sites that "still spell" a path nothing spells),webcore/streams.rs(result::StreamResult),webcore/Request.rs(js_gen::from_js*),webcore/FormData.rs(get_boundary),s3/client.rs(multipart::{self}),bake/mod.rs(FrameworkRouteralias,DynamicRouteMap/EncodedPattern/Route/StaticRouteMap,production::{EntryPointMap, TypeAndFlags}),bake/dev_server/mod.rs(Assets,IncrementalGraph,RouteBundle,SourceMapStore),server/mod.rs(BunInfo,PreparedRequestFor,ServerInitContext,ServePluginsState),lib.rs(fivecli::*_commandcrate-root aliases),cli/mod.rs(command::Commandself-alias),cli/Arguments.rs(load_config),allocators/mod.rs,shell/interpreter.rs(Builtin),node/zlib/NativeZstd.rs(Context),api/JSBundler.rs(Config,MiniImportRecord),api/BunObject.rs(JSZstd::deallocator, whose own comment says "0 C++ refs, 0 Rust refs"),api/bun/Terminal.rs(from_js,from_js_direct) andapi/bun/h2_frame_parser.rs(the CamelCaseH2FrameParserConstructortwin of the snake_case alias the js2native thunk actually calls).server_body.rs,FrameworkRouter.rsandproduction.rswere reachable only through the deleted re-exports; they becomepub(crate)(rustc'sunreachable_pubdemands it), and nothing else in them turned out to be dead.bun_runtimeitems (about 110 lines)streams::Writable::{TemporaryAndDone, IntoArray, IntoArrayAndDone}are never produced (theStreamResultvariants of the same names are; theWritableones only hadto_jsarms).WritableFuture::Handleris never armed: the only construction is inside therun()arm that matches an existingHandler, soWritableHandler,WritableHandlerFnand that arm go with it.DrainResult::Empty(webcore.rs, twomatches!inBody.rs, one arm inByteStream.rs),ReadableStream::Source::Direct(the C++Tag::Directmaps toNoneinfrom_js; the FFITagenum itself is untouched),pretty_format::Tag::ArrayBuffer(JSType::ArrayBuffermaps toTag::TypedArray; the now-unreachable_ => {}arm ofprint_asgoes too),shell::IoKind::Stdin,node_fs_watcher::Event::Close(EventType::Close, which is used, stays),cron::CalendarError::OutOfMemory,thumbhash::DecodeError::OutOfMemory.ServerLike::{SSL_ENABLED, DEBUG_MODE, vm_mut}(RequestContextuses its own const generics; the inherentNewServer::vm_mutis still used and stays) andResponseLike::upgradewith both impls (the HMR upgrade goes through the inherentuwsmethods).Other crates (about 60 lines)
bun_core:strings::rsplit_once(the_charvariant is used, this one is not), theCodePointZerore-export inimmutable.rs, and theZERO_VALUE/MAXassociated consts ofCodePointZero(both impls;from_u32is what the decoders use).bun_css:css_parser::CustomMediaandIdentFns, the crate-rootCustomIdentFns/DashedIdentFns,container::ContainerNameFns,selector::{_PrintErr, _Printer}("re-export alias parity"), and the path re-export of thecss_eql_partialeq!macro (every use is textual).bun_install:PackageManager::{do_patch_commit, prepare_patch, GitResolver}, crate-rootFolderResolutionandPostinstallOptimizer,patch_install::PatchedDep.bun_bundler:LinkerContext::{OutputFileListBuilder, StaticRouteVisitor, do_step5}module aliases,bundle_v2::{AdditionalFile, IndexStringMap},options::BakeExtra.bun_collections::ArrayListAlignedInandbun_sql_jsc::mysql::MySQLRequestQueuecrate-level re-exports,bun_jsc::ZigErrorTypecrate-root re-export (the type is used by path).windows_sys::kernel32::SetFileTime(itsfutimenscaller was rewritten) andlsquic_sys::lsquic_conn_n_pending_streams.ErrorCode.ts: 17 codes with no producer ($ERR_X(in src/js,ErrorCode::ERR_Xin C++,ErrorCode::Xin Rust, none in tests or docs):ERR_BUFFER_CONTEXT_NOT_AVAILABLE,ERR_CRYPTO_INITIALIZATION_FAILED,ERR_CRYPTO_INVALID_COUNTER,ERR_CRYPTO_INVALID_TAG_LENGTH,ERR_CRYPTO_JOB_INIT_FAILED,ERR_CRYPTO_SCRYPT_INVALID_PARAMETER,ERR_EXECUTION_ENVIRONMENT_NOT_AVAILABLE,ERR_INVALID_ADDRESS,ERR_INVALID_PACKAGE_CONFIG,ERR_MESSAGE_TARGET_CONTEXT_UNAVAILABLE,ERR_MISSING_PLATFORM_FOR_WORKER,ERR_NON_CONTEXT_AWARE_DISABLED,ERR_REQUIRE_ASYNC_MODULE,ERR_TLS_PSK_SET_IDENTITY_HINT_FAILED,ERR_WASI_NOT_STARTED,ERR_WORKER_INIT_FAILED,ERR_SECRETS_NOT_AVAILABLE. Everything that consumes the table is generated from it, so the renumbering is invisible.Fix
pub usegroups, the sevenpub->pub(crate)changes, and the comments that named the removed items:JSBundler.rs'sOutputKindnote,api.rs,production.rs, the two SAFETY comments that citedServerLike::vm_mut, and theByteStream.rs/FormData.rscomments that namedDrainResult::Empty/get_boundary, which were trimmed to a line and removed respectively).dead_code = deny, so the only dead Rust left ispubitems, which rustc exempts. For every crate,pubwas temporarily demoted topub(crate)on the items no file outside the crate mentions (and, forbun_runtime, on everything the codegen output andbun_bindo not mention), andcargo check -p <crate>was run forx86_64-unknown-linux-gnu,x86_64-pc-windows-msvcandaarch64-apple-darwin. An item was only deleted when rustc reported it unused on all three; items it reported on one target only (ipc.rs,node_fs.rs,cron.rs's Windows and macOS error variants, theapi.rssocket aliases) and items only reached through macros expanded in other crates (bun_alloc's zone methods,bun_clap's const-eval helpers,js_class_module!'sIntoRawMut) were kept. The C++ was checked at link level (nmover every object pluslibbun_rust.a); everything unreferenced there is either already in an open PR or a virtual override.bun bd(regenerates the class, js2native, host-export and error-code codegen and links; the regeneratedgenerated_classes.rsandgenerated_js2native.rsare byte-identical to before,generated_host_exports.rsdiffers only in source line-number comments),bun run rust:check-all(12 of 12 targets ok),bun bd testontest/js/web/streams/streams.test.js,test/js/web/fetch/body-stream.test.ts,test/js/node/watch/fs.watch.test.ts,test/js/bun/shell/{bunshell,commands/echo,commands/rm}.test.ts,test/js/node/util/parse_args/parse-args-null-config.test.ts,test/js/node/url/url-fileurltopathbuffer.test.tsandtest/js/node/crypto/crypto-oneshot.test.ts(all pass;test/js/bun/test/pretty-format-overflow.test.tssegfaults on a 500-deep object in this debug+ASAN build exactly the same withmain'spretty_format.rsswapped back in, and passes at depth 300 and on the release binary, so it is a debug stack-depth limit rather than anything here), and the new source linttest/internal/source-lints/dead-symbols-runtime-reexports-misc.test.ts(all five of its tests fail againstmain, every check firing, and pass here).Left alone (for a later run)
webcore.rs'sDOMExceptionCode/web_worker(Remove dead code from C++ bindings, bindgen glue, ast, and orphaned scripts #37149),install/lib.rs'sTextLockfile(Remove dead code from install, webcore, jsc, sha_hmac, and misc crates #37089 edits the adjacent line),valkey_jsc/js_valkey.rs'sclose_subscription_ctxpair (Remove dead code from simdutf, ncrypto, uws shims, and JSC/WebCore bindings #38439, under its pre-refactor name),api/bun/spawn.rsandffi/mod.rsre-exports (Remove dead code from install, webcore, jsc, sha_hmac, and misc crates #37089, Delete the unused draft FFI host function implementation #37362; two more of them became unused by this PR),zlib_sys::inflateBackInit_in both backends (Remove dead code from simdutf, ncrypto, uws shims, and JSC/WebCore bindings #38439 edits the Windows one), theERR_REDIS_*andERR_KEY_GENERATION_JOB_FAILEDcodes (Remove dead code from webcore bindings, watcher, node-fallbacks, and misc crates #37062 edits that block),bindgen.rs's three unused marker structs (Remove dead code from C++ bindings, bindgen glue, ast, and orphaned scripts #37149),react_compiler's 1150-line_expvalidation variant (Remove dead code from react_compiler and the node:http2 frame parser #37272).napi_statusvariants,SSRKind::Regular,serialized_failure::ErrorKind's JS variants andMessageId::Visualizer(external code tables),bake::Mode::ProductionDynamic(a documented mode placeholder),GenericIndexInt::from_usize(Remove dead code from bun_core, bun_css, bun_jsc, and the FFI crates #38703 is editing that impl block),ERR_POSTGRES_INVALID_BYTE_SEQUENCE_FOR_ENCODING(documented in docs/runtime/sql.mdx), and the unused entries of theO::,EPOLL::,IN::andPOLL_*constant tables inbun_sys.[review] gate passed · iteration 0 · 54 files touched
fails on main (without fix)
passes on PR (with fix)
diff hotspot
gate history · 1 passed · 0 rejected · iteration 0
evidence per changed file