<commit_before>// Copyright (c) 2013-2015 <NAME>

// ... but permission given for use in this project in accordance
// with the license of this project

#ifndef COMPILER_H
#define COMPILER_H

#include "Platform/Platform.h"

#ifndef TEST
#define TEST ( 0 )
#endif

#ifndef NULL
#if HACKILY_REMOVE_STB_WARNINGS
#define NULL (unsigned long long)( 0 )
#else
#define NULL ( 0 )
#endif
#endif

#if defined( _DEBUG ) && !defined( DEBUG )
#define DEBUG ( 1 )
#elif !defined( DEBUG )
#define DEBUG ( 0 )
#endif

#ifdef _MSC_VER
#define COMPILER_MS ( 1 )
#else
#define COMPILER_MS ( 0 )
#endif

// SE - NOTE: this might actually be one of the Apple clangs
// not sure its worth detecting them both, and what to call the case that works with both...
#ifdef __GNUC__
#define COMPILER_GCC ( 1 )
#else
#define COMPILER_GCC ( 0 )
#endif

#if COMPILER_MS

#define FORCE_INLINE __forceinline

#pragma warning( disable : 4451 )
#pragma warning( disable : 4706 ) // i like assigning in loop conditions...

#ifndef _CRT_SECURE_NO_WARNINGS
#define _CRT_SECURE_NO_WARNINGS
#endif

#define snprintf _snprintf_s

#elif COMPILER_GCC

#define FORCE_INLINE inline
#define __FUNCSIG__ __PRETTY_FUNCTION__

#define _stricmp strcasecmp

#define _malloca alloca
#define _freea( ... )

#define sprintf_s sprintf
#define vsnprintf_s vsnprintf
#define vswprintf_s vswprintf

#else // if !COMPILER_MS

#define FORCE_INLINE inline

#define _stricmp strcasecmp

#define _malloca alloca
#define _freea( ... )

#endif

#if COMPILER_MS
#define UNUSED( x ) (void)( x )
#else
#define UNUSED( x ) (void)((void*)( &x ))
#endif

#define HIDE_BUILT_IN_COPIES( type ) private: type& operator=( const type& ) { return *this; } type( const type& ) {}

#if !WIN
#define _countof( x ) ((int)( sizeof( x ) / sizeof( x[ 0 ] ) ))
#endif

#endif
<commit_msg>Fix for VS2015<commit_after>// Copyright (c) 2013-2015 Cranium Software

// ... but permission given for use in this project in accordance
// with the license of this project

#ifndef COMPILER_H
#define COMPILER_H

#include "Platform/Platform.h"

#ifndef TEST
#define TEST ( 0 )
#endif

#ifndef NULL
#if HACKILY_REMOVE_STB_WARNINGS
#define NULL (unsigned long long)( 0 )
#else
#define NULL ( 0 )
#endif
#endif

#if defined( _DEBUG ) && !defined( DEBUG )
#define DEBUG ( 1 )
#elif !defined( DEBUG )
#define DEBUG ( 0 )
#endif

#ifdef _MSC_VER
#define COMPILER_MS ( 1 )
#else
#define COMPILER_MS ( 0 )
#endif

// SE - NOTE: this might actually be one of the Apple clangs
// not sure its worth detecting them both, and what to call the case that works with both...
#ifdef __GNUC__
#define COMPILER_GCC ( 1 )
#else
#define COMPILER_GCC ( 0 )
#endif

#if COMPILER_MS

#define FORCE_INLINE __forceinline

#pragma warning( disable : 4451 )
#pragma warning( disable : 4706 ) // i like assigning in loop conditions...

#ifndef _CRT_SECURE_NO_WARNINGS
#define _CRT_SECURE_NO_WARNINGS
#endif

#if _MSC_VER < 1900
#define snprintf _snprintf
#endif

#elif COMPILER_GCC

#define FORCE_INLINE inline
#define __FUNCSIG__ __PRETTY_FUNCTION__

#define _stricmp strcasecmp

#define _malloca alloca
#define _freea( ... )

#define sprintf_s sprintf
#define vsnprintf_s vsnprintf
#define vswprintf_s vswprintf

#else // if !COMPILER_MS

#define FORCE_INLINE inline

#define _stricmp strcasecmp

#define _malloca alloca
#define _freea( ... )

#endif

#if COMPILER_MS
#define UNUSED( x ) (void)( x )
#else
#define UNUSED( x ) (void)((void*)( &x ))
#endif

#define HIDE_BUILT_IN_COPIES( type ) private: type& operator=( const type& ) { return *this; } type( const type& ) {}

#if !WIN
#define _countof( x ) ((int)( sizeof( x ) / sizeof( x[ 0 ] ) ))
#endif

#endif

{'fraction_non_alphanumeric': 0.108397365532382, 'fraction_numerical': 0.01646542261251372, 'mean_word_length': 4.3840472673559825, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 4, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3469689', 'n_tokens_mistral': 1386, 'n_tokens_neox': 1303, 'n_words': 445}