🏁 removed __builtin_expect for MSVC
This commit is contained in:
		
							parent
							
								
									d025b6aaf7
								
							
						
					
					
						commit
						6b12e40478
					
				
					 1 changed files with 7 additions and 2 deletions
				
			
		|  | @ -91,8 +91,13 @@ SOFTWARE. | |||
| #endif | ||||
| 
 | ||||
| // manual branch prediction
 | ||||
| #define JSON_LIKELY(x)      __builtin_expect(!!(x), 1) | ||||
| #define JSON_UNLIKELY(x)    __builtin_expect(!!(x), 0) | ||||
| #if defined(__clang__) || defined(__GNUC__) || defined(__GNUG__) | ||||
|     #define JSON_LIKELY(x)      __builtin_expect(!!(x), 1) | ||||
|     #define JSON_UNLIKELY(x)    __builtin_expect(!!(x), 0) | ||||
| #else | ||||
|     #define JSON_LIKELY(x)      x | ||||
|     #define JSON_UNLIKELY(x)    x | ||||
| #endif | ||||
| 
 | ||||
| /*!
 | ||||
| @brief namespace for Niels Lohmann | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue