#13622 and #13624 altered what happens when the `fixed_size` Cargo feature is enabled. Previously, enabling that feature altered behavior of `AllocatorPool`. Now the feature is additive - it does nothing on it's own, but only adds additional APIs, and *those APIs* can be used to alter behavior.
The purpose of the `disable_fixed_size` Cargo feature was to prevent the `fixed_size` feature being activated when tests are run with `--all-features`. Now that enabling `fixed_size` feature doesn't alter behavior, we don't need to worry about it being enabled in tests. Therefore `disable_fixed_size` feature can be removed.
This removes a bunch of `#[cfg]` boilerplate, and ugly hacks which were previously required to workaround feature unification.
#13419 introduced a `BitSet` type which stores its data in the arena, in the mangler.
This type may be useful in other contexts, so move it from `oxc_mangler` into `oxc_allocator`. But put it behind a `bitset` feature, so only crates which use it pay for it.
`AllocatorPool` is only used in linter. Parser, transformer, minifier etc don't need it. So put it behind a `pool` cargo feature.
This complicates the many `#[cfg]` attrs even further, but this is preparation for merging the 2 `AllocatorPool` implementations, and removing the `fixed_size` feature, which will remove a lot of this `#[cfg]` mess.
`README` and doc comment in `lib.rs` were out of sync and both missed out some of `oxc_allocator`'s cargo features. Document all the features in both places.
Follow-on after #12555. Pure refactor.
Move code related to allocation tracking into its own module, and introduce an `AllocationStats` struct.
This reduces noise in `allocator.rs` and `alloc.rs`, with less repetitions of `#[cfg(all(feature = "track_allocations", not(feature = "disable_track_allocations")))]` etc.
Also bulk out the doc comments explaining the unsoundness, and how we must take care to avoid allocation tracking code being compiled in production code.