Differences From Artifact [bc6ad5b4e9]:
- File src/OFBlock.m — part of check-in [5bb771755d] at 2017-07-09 15:29:03 on branch trunk — runtime: Rename include to ObjFW-RT.h (user: js, size: 12465) [annotate] [blame] [check-ins using]
To Artifact [a2a5089265]:
- File
src/OFBlock.m
— part of check-in
[2f4e0df8be]
at
2017-10-17 00:33:37
on branch trunk
— Do not use implicit method return types
Instead, explicitly declare them, as OF_ASSUME_NONNULL_{BEGIN,END} does
not apply to implicit return types. This means that after this commit,
all init methods have a nonnull return type, as they should have. (user: js, size: 12539) [annotate] [blame] [check-ins using]
︙ | ︙ | |||
60 61 62 63 64 65 66 | OF_BLOCK_FIELD_IS_BLOCK = 7, OF_BLOCK_FIELD_IS_BYREF = 8, OF_BLOCK_FIELD_IS_WEAK = 16, OF_BLOCK_BYREF_CALLER = 128 }; @protocol RetainRelease | | | 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 | OF_BLOCK_FIELD_IS_BLOCK = 7, OF_BLOCK_FIELD_IS_BYREF = 8, OF_BLOCK_FIELD_IS_WEAK = 16, OF_BLOCK_BYREF_CALLER = 128 }; @protocol RetainRelease - (instancetype)retain; - (void)release; @end #ifdef OF_OBJFW_RUNTIME /* Begin of ObjC module */ static struct objc_abi_class _NSConcreteStackBlock_metaclass = { (struct objc_abi_class *)(void *)"OFBlock", "OFBlock", "OFStackBlock", |
︙ | ︙ | |||
421 422 423 424 425 426 427 | memcpy(&_NSConcreteMallocBlock, tmp, sizeof(_NSConcreteMallocBlock)); free(tmp); objc_registerClassPair((Class)&_NSConcreteMallocBlock); # endif #endif } | | | | 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 | memcpy(&_NSConcreteMallocBlock, tmp, sizeof(_NSConcreteMallocBlock)); free(tmp); objc_registerClassPair((Class)&_NSConcreteMallocBlock); # endif #endif } + (instancetype)alloc { OF_UNRECOGNIZED_SELECTOR } - (instancetype)init { OF_INVALID_INIT_METHOD } - (void *)allocMemoryWithSize: (size_t)size { OF_UNRECOGNIZED_SELECTOR |
︙ | ︙ | |||
460 461 462 463 464 465 466 | } - (void)freeMemory: (void *)ptr { OF_UNRECOGNIZED_SELECTOR } | | | | | 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 | } - (void)freeMemory: (void *)ptr { OF_UNRECOGNIZED_SELECTOR } - (instancetype)retain { if (object_getClass(self) == (Class)&_NSConcreteMallocBlock) return Block_copy(self); return self; } - (id)copy { return Block_copy(self); } - (instancetype)autorelease { if (object_getClass(self) == (Class)&_NSConcreteMallocBlock) return [super autorelease]; return self; } |
︙ | ︙ |