This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
gl_bindings.rs:17611:30: 17611:56 error: mismatched types: | |
expected `*const libc::types::common::c95::c_void`, | |
found `*const libc::types::common::c95::c_void` | |
(expected enum `libc::types::common::c95::c_void`, | |
found a different enum `libc::types::common::c95::c_void`) [E0308] | |
/Users/keith/Code/Rustermind/target/debug/build/Rustermind-93cd331803113f4a/out/gl_bindings.rs:17611 load_with(|name| loader.get_proc_addr(name)); | |
^~~~~~~~~~~~~~~~~~~~~~~~~~ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
switch (condition) | |
{ | |
case constant: | |
{ | |
// code | |
} | |
break; | |
case simply: | |
// code |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#import <Foundation/Foundation.h> | |
template<class T> | |
T *objc_faithcast(id u) | |
{ | |
assert([u isKindOfClass:[T class]]); | |
return reinterpret_cast<T *>(u); | |
} | |
template<class T, class U> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// c++ -g -std=c++11 -fobjc-arc -framework Foundation test.mm && ./a.out | |
#import <Foundation/Foundation.h> | |
#import <objc/runtime.h> | |
@interface X : NSObject | |
- (void)method1; | |
- (int)method2:(int)arg; | |
- (BOOL)method3:(BOOL)arg; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// c++ -std=c++11 -fobjc-arc -framework Foundation test.mm && ./a.out | |
#import <Foundation/Foundation.h> | |
#import <objc/runtime.h> | |
@interface X : NSObject | |
- (void)method1; | |
- (int)method2:(int)arg; | |
@end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2014-11-13 20:51:24.187 a.out[78021:7001297] int, immediate call of block | |
2014-11-13 20:51:24.188 a.out[78021:7001297] 42 | |
2014-11-13 20:51:24.564 a.out[78025:7001307] int, block called after return | |
2014-11-13 20:51:24.565 a.out[78025:7001307] 42 | |
2014-11-13 20:51:24.921 a.out[78029:7001313] NSString, immediate call of block | |
2014-11-13 20:51:24.922 a.out[78029:7001313] 42 | |
2014-11-13 20:51:25.295 a.out[78033:7001323] NSString, block called after return | |
2014-11-13 20:51:25.297 a.out[78033:7001323] (null) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#import <Foundation/Foundation.h> | |
@interface Foo : NSObject | |
@property (readwrite, copy) void (^array)(); | |
@end | |
@implementation Foo | |
- (id)initWithError:(NSString **)errorHandle; | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-[XPSettingsView tableView:numberOfRowsInSection:]: | |
00000000000005e0 pushq %rbp | |
00000000000005e1 movq %rsp, %rbp | |
00000000000005e4 movl $0x4, %eax | |
00000000000005e9 popq %rbp | |
00000000000005ea retq |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
NSUInteger lengthA = [a length]; | |
NSUInteger lengthB = [b length]; | |
NSUInteger keyLength = lengthA + lengthB + 1; | |
assert(keyLength * sizeof(unichar) < SOME_REASONABLE_MAXIMUM_FOR_STACK_ALLOCATION); | |
unichar cat[keyLength]; | |
[a getCharacters:cat range:NSMakeRange(0, lengthA)]; | |
cat[lengthA] = '.'; | |
[b getCharacters:cat + lengthA + 1 range:NSMakeRange(0, lengthB)]; | |
NSString *key = [[NSString alloc] initWithCharactersNoCopy:cat length:keyLength freeWhenDone:NO]; | |
... [dict objectForKey:key]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- glProgramUniformMatrix4fv(_shaders->program(_vs_spotlight), glGetUniformLocation(_shaders->program(_vs_spotlight), "m"), 1, GL_TRUE, (GLfloat const *)&m); | |
- glProgramUniformMatrix4fv(_shaders->program(_vs_spotlight), glGetUniformLocation(_shaders->program(_vs_spotlight), "mv"), 1, GL_TRUE, (GLfloat const *)&mv); | |
- glProgramUniformMatrix4fv(_shaders->program(_vs_spotlight), glGetUniformLocation(_shaders->program(_vs_spotlight), "v"), 1, GL_TRUE, (GLfloat const *)&v); | |
- glProgramUniformMatrix4fv(_shaders->program(_vs_spotlight), glGetUniformLocation(_shaders->program(_vs_spotlight), "mvp"), 1, GL_TRUE, (GLfloat const *)&mvp); | |
- glProgramUniformMatrix4fv(_shaders->program(_vs_spotlight), glGetUniformLocation(_shaders->program(_vs_spotlight), "shadow_mvp"), 1, GL_TRUE, (GLfloat const *)&shadow_mvp); | |
- glProgramUniform4fv(_shaders->program(_vs_spotlight), glGetUniformLocation(_shaders->program(_vs_spotlight), "worldspace_light_pos"), 1, (GLfloat c |