Skip to content

code_style: use switch expressions for simple value mapping #1579

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from

Conversation

NathanBaulch
Copy link
Contributor

Switch expressions provide a nice compact way to convert values, especially to/from enums.
This PR introduces switch expressions where they make sense, in particular a new Models.Change.ChangeStateFromCode function (feel free to rename) that dramatically simplifies the QueryLocalChanges command.

@love-linger love-linger force-pushed the develop branch 6 times, most recently from 05dba32 to 6822ae3 Compare July 21, 2025 09:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant