Skip to content

Instantly share code, notes, and snippets.

View mikekazakov's full-sized avatar

Michael G. Kazakov mikekazakov

  • SNPS
  • Exeter, UK
View GitHub Profile
static std::string GetRealPath(const char *_path_in)
{
return _path_in;
}
#include <memory>
#include <utility>
#include <string>
#include <iostream>
template <class T>
struct Indirect
{
T *value = nullptr;
int ref_count = 0;
@mikekazakov
mikekazakov / xcode9gm_objc_bug2.mm
Created September 21, 2017 03:39
Xcode9GM problem with Objective-C++ N2
// clang++ -std=c++1z -fobjc-arc -framework Foundation
#import <Cocoa/Cocoa.h>
#include <functional>
@interface C : NSObject
@property (nonatomic) std::function<void()> f;
@end
@implementation C
@end
@mikekazakov
mikekazakov / xcode9gm_objc_bug1.mm
Created September 21, 2017 03:37
Xcode9GM problem with Objective-C++ N1
// clang++ -std=c++1z -fobjc-arc -framework Foundation
#import <Cocoa/Cocoa.h>
#include <functional>
@interface C : NSObject
@property (nonatomic) std::function<void()> f;
@end
@implementation C
@end