[turbopack] Create a macro rcstr! for constructing RcStr from string literals. (#79759)
## Add `rcstr!` macro for efficient string literal handling ### What? This PR introduces a new `rcstr!` macro that creates `RcStr` instances from string literals, optimizing for inline storage when possible and using `LazyLock` for longer strings. ### Why? The `rcstr!` macro provides several benefits: - Allows compile-time evaluation of inline strings - Caches longer strings using `LazyLock` to avoid repeated allocations
Showing
Please
register
or
sign in
to comment