Closed SAGESSE-CN closed 4 years ago
@sagesse-cn I'm not seeing any errors compiling on Xcode 12 beta 6. Can you provide more info?
Specifically, if you could point out how I can reproduce it, that would be very helpful!
When we install the pod PINRemoteImage - it installs with following pods
Installing PINCache (3.0.1-beta.8) Installing PINOperation (1.1.2) Installing PINRemoteImage (3.0.0)
To update as suggested - when we install PINCache it updates to latest version but installs an older version of PINRemoteImage and followings pods.
Installing FLAnimatedImage (1.0.12) Installing PINCache 3.0.1 (was 3.0.1-beta.8) Installing PINOperation 1.2 (was 1.1.2) Installing PINRemoteImage 2.1.4 (was 3.0.0)
This gives 4 build errors - screenshots below
Hope this helps in recreating the issue.
Specifically, if you could point out how I can reproduce it, that would be very helpful!
In any dependent PINCache project.
PINMemoryCache *cache = [[PINMemoryCache alloc] init];
cache.didAddObjectBlock = ^(PINMemoryCache *cache, NSString * _Nonnull key, id _Nullable object) {
// do something.
};
The compile error in PINCache project was fixed in #276.
But that solution was not the best, any users for using PINCache may need to make a lot of changes.
The block signature is void(^)(PINMemoryCache *, NSString *, id)
, this is a correct signature, can't limit users must to use void(^)(id<PINCaching>, NSString *, id)
.
A better solution is to add the __kindof
into id<PINCaching>
, user not need to modify code, just simply update the Cocoapods dependency.
About why must to add __kindof
, see reference.
Thx!
Could we get some traction on this PR, What is currently blocking it?
What is holding up approval of this PR? I cannot get my work done without it.
Reference: https://reviews.llvm.org/D66831#2019125
I get the latest with your changes and I still get two incompatible pointers.
PINCache.m line 109;
[self->_memoryCache objectForKeyAsync:key completion:^(PINMemoryCache
and line 232:
[_diskCache synchronouslyLockFileAccessWhileExecutingBlock:^(PINDiskCache *diskCache)
Reference: https://reviews.llvm.org/D66831#2019125
@sagesse-cn
Reference: https://reviews.llvm.org/D66831#2019125
@sagesse-cn
Can you provide more information, a demo that depyon to pincache?
Reference: https://reviews.llvm.org/D66831#2019125
@sagesse-cn
Can you provide more information, a demo that depyon to pincache?
@sagesse-cn My bad, the pod updates but something somewhere in this large legacy project I took over is specifying an earlier version of PINCache, so in my Xcode project it is an old version.
Reference: https://reviews.llvm.org/D66831#2019125