Thread with 3 posts
jump to expanded post#import "Foundation/Foundation.h"
#include <objc/message.h>
#include <objc/runtime.h>
@interface Infinite: NSObject
@end
@implementation Infinite: NSObject
@end
int main(void)
{
class_addMethod([Infinite self], @selector(loop), objc_msgSend, "@@:");
[[Infinite new] loop];
return 0;
}
this is an objective-c shitpost
local girl discovers secret trick to find out whether the objective-c implementation uses tail calls in objc_msgSend. runtime maintainers hate her