|  | @ -1,5 +1,7 @@ | 
			
		
	
		
		
			
				
					|  |  | #pragma once |  |  | #pragma once | 
			
		
	
		
		
			
				
					|  |  | 
 |  |  | 
 | 
			
		
	
		
		
			
				
					|  |  |  |  |  | // TODO: move to independent repo
 | 
			
		
	
		
		
			
				
					|  |  |  |  |  | 
 | 
			
		
	
		
		
			
				
					|  |  | /// The Exposer can forcibly access private members of a class without changing
 |  |  | /// The Exposer can forcibly access private members of a class without changing
 | 
			
		
	
		
		
			
				
					|  |  | /// any code, and in most scenarios, it has zero over-cost. This exposer using
 |  |  | /// any code, and in most scenarios, it has zero over-cost. This exposer using
 | 
			
		
	
		
		
			
				
					|  |  | /// macros to construct function that return a reference of target variable or
 |  |  | /// macros to construct function that return a reference of target variable or
 | 
			
		
	
	
		
		
			
				
					|  | @ -49,11 +51,17 @@ struct Exposer { | 
			
		
	
		
		
			
				
					|  |  | 
 |  |  | 
 | 
			
		
	
		
		
			
				
					|  |  | #define UNIQUE_TAG UNIQUE_TAG_IMPL(__COUNTER__) |  |  | #define UNIQUE_TAG UNIQUE_TAG_IMPL(__COUNTER__) | 
			
		
	
		
		
			
				
					|  |  | 
 |  |  | 
 | 
			
		
	
		
		
			
				
					
					|  |  | #define NS_EXPOSER_START \ |  |  | // TODO: add GCC warning ignored
 | 
			
				
				
			
		
	
		
		
			
				
					
					|  |  |     namespace {          \ |  |  | 
 | 
			
				
				
			
		
	
		
		
			
				
					
					|  |  |     namespace exposer {  \ |  |  | #define NS_EXPOSER_START             \ | 
			
				
				
			
		
	
		
		
	
		
		
	
		
		
	
		
		
			
				
					|  |  |  |  |  |     namespace {                      \ | 
			
		
	
		
		
			
				
					|  |  |  |  |  |     namespace exposer {              \ | 
			
		
	
		
		
			
				
					|  |  |  |  |  |     _Pragma("clang diagnostic push") \ | 
			
		
	
		
		
			
				
					|  |  |  |  |  |     _Pragma("clang diagnostic ignored \"-Wunused-function\"") | 
			
		
	
		
		
			
				
					|  |  | 
 |  |  | 
 | 
			
		
	
		
		
			
				
					
					|  |  | #define NS_EXPOSER_END }} |  |  | #define NS_EXPOSER_END              \ | 
			
				
				
			
		
	
		
		
	
		
		
			
				
					|  |  |  |  |  |     _Pragma("clang diagnostic pop") \ | 
			
		
	
		
		
			
				
					|  |  |  |  |  |     }} | 
			
		
	
		
		
			
				
					|  |  | 
 |  |  | 
 | 
			
		
	
		
		
			
				
					|  |  | // ----------------------------------------------------------------------------------------- //
 |  |  | // ----------------------------------------------------------------------------------------- //
 | 
			
		
	
		
		
			
				
					|  |  | 
 |  |  | 
 | 
			
		
	
	
		
		
			
				
					|  | 
 |