From 2f80bfccad9b8ba247872de3307ebfd95139b666 Mon Sep 17 00:00:00 2001 From: yimajo Date: Sat, 17 Aug 2024 19:26:48 +0900 Subject: [PATCH] Add @retroactive to extension to address Xcode 16 warning. --- .../FavoriteFeature/FavoriteView.swift | 8 ++++- .../Sources/SearchFeature/SearchView.swift | 32 ++++++++++++++++--- 2 files changed, 35 insertions(+), 5 deletions(-) diff --git a/app-ios/Sources/FavoriteFeature/FavoriteView.swift b/app-ios/Sources/FavoriteFeature/FavoriteView.swift index 7bd521e8d..6b478cf8e 100644 --- a/app-ios/Sources/FavoriteFeature/FavoriteView.swift +++ b/app-ios/Sources/FavoriteFeature/FavoriteView.swift @@ -82,7 +82,13 @@ public struct FavoriteView: View { } } -extension DroidKaigi2024Day: Selectable { +#if hasFeature(RetroactiveAttribute) +extension DroidKaigi2024Day: @retroactive Selectable {} +#else +extension DroidKaigi2024Day: Selectable {} +#endif + +extension DroidKaigi2024Day { public var id: Self { self } diff --git a/app-ios/Sources/SearchFeature/SearchView.swift b/app-ios/Sources/SearchFeature/SearchView.swift index d716d0aa2..a31942f1c 100644 --- a/app-ios/Sources/SearchFeature/SearchView.swift +++ b/app-ios/Sources/SearchFeature/SearchView.swift @@ -148,7 +148,13 @@ public struct SearchView: View { } } -extension DroidKaigi2024Day: Selectable { +#if hasFeature(RetroactiveAttribute) +extension DroidKaigi2024Day: @retroactive Selectable {} +#else +extension DroidKaigi2024Day: Selectable {} +#endif + +extension DroidKaigi2024Day { public var id: Self { self } @@ -167,7 +173,13 @@ extension DroidKaigi2024Day: Selectable { } } -extension TimetableCategory: Selectable { +#if hasFeature(RetroactiveAttribute) +extension TimetableCategory: @retroactive Selectable {} +#else +extension TimetableCategory: Selectable {} +#endif + +extension TimetableCategory { public var caseTitle: String { title.currentLangTitle } @@ -178,7 +190,13 @@ extension TimetableCategory: Selectable { } } -extension TimetableSessionType: Selectable { +#if hasFeature(RetroactiveAttribute) +extension TimetableSessionType: @retroactive Selectable {} +#else +extension TimetableSessionType: Selectable {} +#endif + +extension TimetableSessionType { public var id: Self { self } @@ -188,7 +206,13 @@ extension TimetableSessionType: Selectable { } } -extension Lang: Selectable { +#if hasFeature(RetroactiveAttribute) +extension Lang: @retroactive Selectable {} +#else +extension Lang: Selectable {} +#endif + +extension Lang { public var id: Self { self }