Skip to content

SystemLabel proc-macro no longer allows for generic enums #5362

@SarthakSingh31

Description

@SarthakSingh31

Bevy version

Since c43295a

The Problem

I was trying to update bevy_mod_raycast to bevy main but ran into a problem with this

https://github.com/bevyengine/bevy/pull/4957/files#diff-b131f1941aa2edc166d44e3411ad3e04c125bd541288357846e6c2e018b46b80R133-R142

change to the SystemLabel proc-macro.

https://github.com/aevyrie/bevy_mod_raycast/blob/0a5d1e3334285eaf85e97adc28b14cbb50ab1b48/src/lib.rs#L82-L89

needs a variant with a data field to store the PhantomData but this change makes that impossible.

Possible solutions

  1. Make the SystemLabel proc-macro detect if the variant is unreachable by insuring that it has a field with type ::std::convert::Infallible.
  2. Add a ignore attribute to the SystemLabel proc-macro.

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-ECSEntities, components, systems, and eventsC-BugAn unexpected or incorrect behavior

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions