Post

Replies

Boosts

Views

Activity

Comment on dispatch_once weird behavior
+ (instancetype)shared { static dispatch_once_t onceToken; static OGAKeyManager *instance = nil; dispatch_once(&onceToken, ^{ instance = [[self alloc] init]; NSLog(@"%@", instance); // prints twice with a different memory address each time (one for each Framework) }); return instance; }
Topic: Programming Languages SubTopic: General Tags:
Sep ’23
Comment on dispatch_once weird behavior
Hi @eskimo, it did not work (see above). Any suggestions ? Thanks a lot!
Topic: Programming Languages SubTopic: General Tags:
Replies
Boosts
Views
Activity
Sep ’23
Comment on dispatch_once weird behavior
My bad, you said to use the link map if it had the same origin. It's not actually :-/ What's your next move master ? ^_^
Topic: Programming Languages SubTopic: General Tags:
Replies
Boosts
Views
Activity
Sep ’23
Comment on dispatch_once weird behavior
Thanks! Actually, as expected, the first Mach-O image is the app, the second is the framework#2. I'll try to investigate with the above link and let you know! Thanks 🙏
Topic: Programming Languages SubTopic: General Tags:
Replies
Boosts
Views
Activity
Sep ’23
Comment on dispatch_once weird behavior
Thanks a lot for your help. What do you mean by You can then look up what Mach-O images contain those addresses.?
Topic: Programming Languages SubTopic: General Tags:
Replies
Boosts
Views
Activity
Sep ’23
Comment on dispatch_once weird behavior
+ (instancetype)shared { static dispatch_once_t onceToken; static OGAKeyManager *instance = nil; dispatch_once(&onceToken, ^{ instance = [[self alloc] init]; NSLog(@"%@", instance); // prints twice with a different memory address each time (one for each Framework) }); return instance; }
Topic: Programming Languages SubTopic: General Tags:
Replies
Boosts
Views
Activity
Sep ’23
Comment on SwiftUI previews not working inside workspace
Maybe, I'm using the latest 14.3.1. But since it's a framework, I don't have any application I can run in the simulator 😓
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Replies
Boosts
Views
Activity
Aug ’23
Comment on Dynamic typealiases on enum
Ok thanks for your answer :-) I'm just glad I'm not the only one who struggles with that :D
Topic: Programming Languages SubTopic: Swift Tags:
Replies
Boosts
Views
Activity
Jul ’23
Comment on Dynamic typealiases on enum
I answered below @Polyphonic , if you have time to check it out ;-) Thanks
Topic: Programming Languages SubTopic: Swift Tags:
Replies
Boosts
Views
Activity
Jul ’23
Comment on SwiftUI and Clean Architecture
No it's a standard struct. What's the point of a @State object if not telling the View that it's datasource has changed ? I don't thing that PhotoContainer has to be an ObservableOject no ? Thanks ;-)
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Replies
Boosts
Views
Activity
Mar ’23