-
-
Notifications
You must be signed in to change notification settings - Fork 251
Closed
godot-rust/godot-rust.github.io
#14Labels
documentationImprovements or additions to documentationImprovements or additions to documentation
Description
on https://godot-rust.github.io/dev/september-2025-update/, Ergonomics and developer experience - Class dispatching part, the example code can't work:
let simple_dispatch: i32 = match_class!(event, {
button @ InputEventMouseButton => 1,
motion @ InputEventMouseMotion => 2,
action @ InputEventAction => 3,
_ => 0, // Fallback.
});
It seems that it should be:
let simple_dispatch: i32 = match_class! { event,
button @ InputEventMouseButton => 1,
motion @ InputEventMouseMotion => 2,
action @ InputEventAction => 3,
_ => 0, // Fallback.
};
according to the source code comments
Houtamelo and Yarwin
Metadata
Metadata
Assignees
Labels
documentationImprovements or additions to documentationImprovements or additions to documentation