<commit_before>#ifndef ENV_H_
#define ENV_H_

#if ! defined TT_MANGLED
#	if defined ENV_POSIX
#		include "posix/env.h"
#	elif defined ENV_MSP430
#		include "msp430/env.h"
#	elif defined ENV_AVR
#		include "avr5/env.h"
#	elif defined ENV_PIC18
#		include "pic18/env.h"
#	elif defined ENV_ARM7
#		include "arm7/env.h"
#	elif defined ENV_MIPS
#		include "mips/env.h"
#	elif defined ENV_SKEL
#		include "skel/env.h"
#	else
#		error Unknown environment.
#	endif
#endif

/* ************************************************************************** */
/* ********************************** DEFAULT ******************************* */
/* ************************************************************************** */

/**
 * \brief Environment thread entry macro.
 *
 * If the environment did not supply this macro then supply default
 * of nothing.
 */
#ifndef ENV_THREAD_ENTRY
#	define ENV_THREAD_ENTRY
#endif

/**
 * \brief Environment inline macro.
 *
 * If the environment did not supply a definition for this then default to
 * nothing. Not all environments allow for the inline keyword(it's C99 not C89).
 */
#ifndef ENV_INLINE
#	define ENV_INLINE
#endif

/**
 * \brief Environment fast code macro.
 *
 * If the environment does not supply a defenition for this the default is
 * nothing. This really only makes sense on the arm7 where we want to force
 * the linking of the functions into SRAM since it's the only thing that is
 * read in 1 cycle.
 */
#ifndef ENV_CODE_FAST
#	define ENV_CODE_FAST
#endif

/* ************************************************************************** */
/* *********************************** SANITY ******************************* */
/* ************************************************************************** */

#ifndef ENV_INIT
#	error Environment did not define ENV_INIT().
#endif

#ifndef ENV_PROTECT
#	error Environment did not define ENV_PROTECT().
#endif

#ifndef ENV_ISPROTECTED
#	error Environment did not define ENV_PROTECTED().
#endif

#ifndef ENV_DEBUG
#	error Environment did not define ENV_DEBUG().
#endif

#ifndef ENV_PANIC
#	error Environment did not define ENV_PANIC().
#endif

#ifndef ENV_NUM_THREADS
#	error Environment did not define ENV_NUM_THREADS.
#endif

#ifndef ENV_CONTEXT_INIT
#	error Environment did not define ENV_CONTEXT_INIT().
#endif

#ifndef ENV_CONTEXT_DISPATCH
#	error Environment did not define ENV_CONTEXT_DISPATCH().
#endif<commit_msg>Made ENV_DEBUG() non-mandatory.<commit_after>#ifndef ENV_H_
#define ENV_H_

#if ! defined TT_MANGLED
#	if defined ENV_POSIX
#		include "posix/env.h"
#	elif defined ENV_MSP430
#		include "msp430/env.h"
#	elif defined ENV_AVR
#		include "avr5/env.h"
#	elif defined ENV_PIC18
#		include "pic18/env.h"
#	elif defined ENV_ARM7
#		include "arm7/env.h"
#	elif defined ENV_MIPS
#		include "mips/env.h"
#	elif defined ENV_SKEL
#		include "skel/env.h"
#	else
#		error Unknown environment.
#	endif
#endif

/* ************************************************************************** */
/* ********************************** DEFAULT ******************************* */
/* ************************************************************************** */

/**
 * \brief Environment thread entry macro.
 *
 * If the environment did not supply this macro then supply default
 * of nothing.
 */
#ifndef ENV_THREAD_ENTRY
#	define ENV_THREAD_ENTRY
#endif

/**
 * \brief Environment inline macro.
 *
 * If the environment did not supply a definition for this then default to
 * nothing. Not all environments allow for the inline keyword(it's C99 not C89).
 */
#ifndef ENV_INLINE
#	define ENV_INLINE
#endif

/**
 * \brief Environment fast code macro.
 *
 * If the environment does not supply a defenition for this the default is
 * nothing. This really only makes sense on the arm7 where we want to force
 * the linking of the functions into SRAM since it's the only thing that is
 * read in 1 cycle.
 */
#ifndef ENV_CODE_FAST
#	define ENV_CODE_FAST
#endif

/**
 * \brief Environment debug macro.
 *
 * The debug macro is NOT neccesary but can be helpfull.
 */
  
#ifndef ENV_DEBUG
#	define ENV_DEBUG(msg) ((void)0)
#endif

/* ************************************************************************** */
/* *********************************** SANITY ******************************* */
/* ************************************************************************** */

#ifndef ENV_INIT
#	error Environment did not define ENV_INIT().
#endif

#ifndef ENV_PROTECT
#	error Environment did not define ENV_PROTECT().
#endif

#ifndef ENV_ISPROTECTED
#	error Environment did not define ENV_PROTECTED().
#endif

#ifndef ENV_PANIC
#	error Environment did not define ENV_PANIC().
#endif

#ifndef ENV_NUM_THREADS
#	error Environment did not define ENV_NUM_THREADS.
#endif

#ifndef ENV_CONTEXT_INIT
#	error Environment did not define ENV_CONTEXT_INIT().
#endif

#ifndef ENV_CONTEXT_DISPATCH
#	error Environment did not define ENV_CONTEXT_DISPATCH().
#endif
{'fraction_non_alphanumeric': 0.2488834754364596, 'fraction_numerical': 0.007917174177831911, 'mean_word_length': 5.02322738386308, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, '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': '6358470', 'n_tokens_mistral': 1553, 'n_tokens_neox': 1479, 'n_words': 480}