Closed myster-t closed 8 years ago
What version of BlocksKit
are you running?
The latest through cocoapods. 2.2.5 I believe.
I have the same issue, I suspect it's not depend on 32 or 64 bit devices. I got this only in swift. The problem is in the last argument of handler block. I tried to use NSInteger or Int(!) argument with no success.
++
Quick and filthy hack to make it work, by special casing this situation and this situation alone. Not written with brevity in mind but to show the special casing step by step:
for (NSUInteger i = 2; i < numberOfArguments; i++) {
const char methodArgument = [methodSignature getArgumentTypeAtIndex:i][0];
const char blockArgument = [blockSignature getArgumentTypeAtIndex:i - 1][0];
if (methodArgument != blockArgument) {
if (@encode(int)[0] == methodArgument && @encode(long)[0] == blockArgument) {
return YES;
}
return NO;
}
}
Thanks @zwaldowski for addressing this. I haven't moved to swift yet. Does your fix also work for obj-c?
@zwaldowski I have run into this issue as well. Will the commits on next branch including the fix for #260 be available on master soon?
Yes, absolutely. We wanted to get a few things into the next
branch first.
Any news on this side? The issue still exist
Just ran into this.
I'm experiencing an intermittent bug when showing UIAlertView's through blockskit's shortcut
bk_showAlertViewWithTitle:...
. The crash:If you comment out the lines 177-179 in A2BlockInvocation.m, then everything works fine. It seems to be more prevalent in older generation phones (iphone 4/4s, iphone 5...). Could this have something to do with how
isSignature:compatibleWithSignature:
works on 32 bit devices vs 64 bit devices?As for whether or not the block signatures are actually incorrect... I've triple checked every single one and they're correct.