SIGN IN SIGN UP
bevyengine / bevy UNCLAIMED

A refreshingly simple data-driven game engine built in Rust

0 0 59 Rust

Reduce bsn! codegen / debug symbols by combining scene implementations (#24124)

# Objective

`bsn!` currently generates a lot of new types: one for each patch, which
then get assembled into a single Scene impl by composing them in a
tuple. This gives the compiler more work to do (types to verify, code to
generate, etc). It also makes our debug symbols bigger / harder to read.

## Solution

Combine `bsn!` entries, where possible, into a single `SceneFunction<F>`
implementation of `Scene`, which does all of the "scene patch" logic
internally. This significantly cuts down on codegen, and also makes the
functional behavior of a `bsn!` block more clear when expanded.
C
Carter Anderson committed
6c0eb84e313a2c79e41922d5bd7009a4f6dd2d14
Parent: 1554049
Committed by GitHub <noreply@github.com> on 5/6/2026, 9:16:44 PM