Post

Replies

Boosts

Views

Activity

Previews are not building for the SwiftDataCardSample project.
I set my active schema to SwiftDataCardSampleEnd, open ContentView.swift, and bring up the Canvas. When I click the little refresh button I get the follow error from Canvas: == DATE: Friday, July 14, 2023 at 9:02:26 AM Eastern Daylight Time 2023-07-14T13:02:26Z == PREVIEW UPDATE ERROR: SchemeBuildError: Failed to build the scheme ”SwiftDataFlashCardSampleEnd” linker command failed with exit code 1 (use -v to see invocation) Link SwiftDataFlashCardSample (arm64): ld: Undefined symbols: unsafeMutableAddressor of self #1 : SwiftDataFlashCardSample.Card in SwiftDataFlashCardSample.Card.creationDate.init : Foundation.Date, referenced from: SwiftDataFlashCardSample.Card.creationDate.init : Foundation.Date in Card.o unsafeMutableAddressor of self #1 : SwiftDataFlashCardSample.Card in SwiftDataFlashCardSample.Card.back.init : Swift.String, referenced from: SwiftDataFlashCardSample.Card.back.init : Swift.String in Card.o unsafeMutableAddressor of self #1 : SwiftDataFlashCardSample.Card in SwiftDataFlashCardSample.Card.front.init : Swift.String, referenced from: SwiftDataFlashCardSample.Card.front.init : Swift.String in Card.o clang: error: linker command failed with exit code 1 (use -v to see invocation) I've made a similar preview in another project where I define a model and I try to use that model in a SwiftUI Canvas preview. I get a very similar error. Basically Canvas is saying it can't find the symbols for the properties on the type. Is there something I'm missing here? Some hidden build setting I need to flip. Or is this just busted?
4
0
1.1k
Jul ’23