AnyCodable icon indicating copy to clipboard operation
AnyCodable copied to clipboard

Xcframework issue

Open johndpope opened this issue 3 years ago • 3 comments

https://github.com/supabase-community/supabase-swift/issues/38

At the bottom of this ticket I’ve successfully exported any cod able along with 6-7 other frameworks but then hit a snag with this library. Are you aware that this actually works with say Bazel uses x frameworks?

UPDATE

https://stackoverflow.com/questions/34159442/x-is-not-a-member-type-of-y


_When using an xcframework that depends on another framework, the X is not a member of type Y will also happen for the Framework it depends on when writing an extensions that wraps, for example, delegate methods

Example: Framework Foo depends on Bar and need to conform to DataDelegate.

class Foo {
    ...
}

extension Foo : Bar.DataDelegate {
    ...
}
Everything during compiling will go as planned and the xcframework will be generated. Once you add it to your App along with the dependancy framework Bar and try to build it you will get DataDelegate is not a member of type Bar._

johndpope avatar Sep 04 '22 03:09 johndpope

build logs

https://gist.github.com/wweevv-johndpope/4fecec0e6b9369ab8220e0becb40fe3f

https://github.com/apple/swift/issues/56573

we can't have AnyCodable module name + AnyCodable class together - have to rename one or the other.

how bout AnyCodableKit?

wweevv-johndpope avatar Sep 05 '22 00:09 wweevv-johndpope

Are there any activity planed for the rename? We're facing the same issue and would appreciate a fix.

stidch avatar Apr 20 '23 20:04 stidch

I think I got around it by importing classes into project....

johndpope avatar Apr 21 '23 19:04 johndpope