<commit_before>#ifndef SCOMMON_H
#define SCOMMON_H
#ifdef __cplusplus
extern "C" {
#endif

/*
 * scommon.h
 *
 * Common definitions.
 *
 * Copyright (c) 2015-2016, <NAME>. All rights reserved. Released under
 * the BSD 3-Clause License (see the doc/LICENSE file included).
 */

#include "sconfig.h"

#ifdef _MSC_VER
	#define _CRT_SECURE_NO_WARNINGS
	#define _CRT_NONSTDC_NO_DEPRECATE
	#include <crtdefs.h>
	#include <BaseTsd.h>
	#include <malloc.h>
	/* MS VC don't support UTF-8 in sprintf, not even using _setmbcp(65001)
	 * and "multi-byte character set" compile mode.
	 */
	#define S_NOT_UTF8_SPRINTF
#else
	#include <sys/types.h>
#endif

#ifdef S_MINIMAL /* microcontroller-related */
	#define S_NOT_UTF8_SPRINTF
#endif

#if !defined(BSD4_3) && !defined(BSD4_4) && !defined(__FreeBSD__) && !defined(_MSC_VER)
	#include <alloca.h>
#endif
#include <stddef.h>
#include <stdarg.h>
#include <string.h>
#include <stdlib.h>
#include <limits.h>
#include <stdio.h>
#include <ctype.h>
#include <wctype.h>
#include <wchar.h>

/*
 * C99 requires to define __STDC_LIMIT_MACROS before stdint.h if in C++ mode
 * (WG14/N1256 Committee Draft 20070907 ISO/IEC 9899:TC3, 7.18.2, page 257)
 */
#if defined(__cplusplus) && __cplusplus <= 19971L
#define __STDC_LIMIT_MACROS
#endif
#include <stdint.h>

/*
 * Context
 */

#if defined(__STDC_VERSION__) && __STDC_VERSION__ >= 199901L || \
    __cplusplus >= 19971L || defined(_MSC_VER) && _MSC_VER >= 1800
	#define S_C99_SUPPORT
#endif

#if defined(S_C99_SUPPORT) || defined(__GNUC__) || defined (__TINYC__)
	#define S_MODERN_COMPILER
	#define S_USE_VA_ARGS
#endif

#ifdef S_C99_SUPPORT<commit_msg>fix build for clang++ 3.0<commit_after>#ifndef SCOMMON_H
#define SCOMMON_H
#ifdef __cplusplus
extern "C" {
#endif

/*
 * scommon.h
 *
 * Common definitions.
 *
 * Copyright (c) 2015-2016, <NAME>. All rights reserved. Released under
 * the BSD 3-Clause License (see the doc/LICENSE file included).
 */

#include "sconfig.h"

#ifdef _MSC_VER
	#define _CRT_SECURE_NO_WARNINGS
	#define _CRT_NONSTDC_NO_DEPRECATE
	#include <crtdefs.h>
	#include <BaseTsd.h>
	#include <malloc.h>
	/* MS VC don't support UTF-8 in sprintf, not even using _setmbcp(65001)
	 * and "multi-byte character set" compile mode.
	 */
	#define S_NOT_UTF8_SPRINTF
#else
	#include <sys/types.h>
#endif

#ifdef S_MINIMAL /* microcontroller-related */
	#define S_NOT_UTF8_SPRINTF
#endif

#if !defined(BSD4_3) && !defined(BSD4_4) && !defined(__FreeBSD__) && !defined(_MSC_VER)
	#include <alloca.h>
#endif
#include <stddef.h>
#include <stdarg.h>
#include <string.h>
#include <stdlib.h>
#include <limits.h>
#include <stdio.h>
#include <ctype.h>
#include <wctype.h>
#include <wchar.h>

/*
 * C99 requires to define __STDC_LIMIT_MACROS before stdint.h if in C++ mode
 * (WG14/N1256 Committee Draft 20070907 ISO/IEC 9899:TC3, 7.18.2, page 257)
 */
#ifdef __cplusplus
#define __STDC_LIMIT_MACROS
#endif
#include <stdint.h>

/*
 * Context
 */

#if defined(__STDC_VERSION__) && __STDC_VERSION__ >= 199901L || \
    __cplusplus >= 19971L || defined(_MSC_VER) && _MSC_VER >= 1800
	#define S_C99_SUPPORT
#endif

#if defined(S_C99_SUPPORT) || defined(__GNUC__) || defined (__TINYC__)
	#define S_MODERN_COMPILER
	#define S_USE_VA_ARGS
#endif

#ifdef S_C99_SUPPORT
{'fraction_non_alphanumeric': 0.1330657610373572, 'fraction_numerical': 0.045384377894411854, 'mean_word_length': 4.8483754512635375, 'pattern_counts': {'":': 0, '<': 36, '<?xml version=': 0, '>': 41, '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': '764153', 'n_tokens_mistral': 1427, 'n_tokens_neox': 1295, 'n_words': 307}