Skip to content
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

Update for Xcode 16 #77

Merged
merged 3 commits into from
Jun 26, 2024
Merged

Update for Xcode 16 #77

merged 3 commits into from
Jun 26, 2024

Conversation

g-mark
Copy link
Contributor

@g-mark g-mark commented Jun 26, 2024

Updates how types are declared to be compatible with Xcode 16.

Specifically, using default types for associatedtypes in combination with inherited protocols and other generic typealiases - and when a concrete ScreenModule omits an Output type.

E.g.:

protocol StoreModule {
  associatedtype Action = NoAction
  associatedtype State = EmptyState
  associatedtype Output = NoOutput
}

protocol ScreenModule: StoreModule {

  associatedtype ConcreteStore: Lasso.ConcreteStore
    where ConcreteStore.State == State,
    ConcreteStore.Action == Action,
    ConcreteStore.Output == Output
}

enum SomeModule: ScreenModule { <-- ERROR, does not conform to ScreenModule
  enum Action { }
  struct State: { }
}

The fix is to move the default values out of the StoreModule and into an extension to get the same idea of default types.

@g-mark g-mark marked this pull request as ready for review June 26, 2024 13:48
Copy link
Contributor

@valentinskukjansww valentinskukjansww left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @g-mark

@g-mark g-mark merged commit 5f18bc6 into develop Jun 26, 2024
8 checks passed
@g-mark g-mark deleted the steven/feature/xcode16 branch June 26, 2024 18:51
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.

2 participants