<commit_before>// Copyright 2003-2009 <NAME>.
// This source comes from the yidl project. It is licensed under the GPLv2 (see COPYING for terms and conditions).

#ifndef _YIDL_H_
#define _YIDL_H_

#include <cstring>
#include <ostream>
#include <string>

#ifdef _WIN32
#define __STDC_LIMIT_MACROS
#include "msstdint.h"
#else
#include <sys/uio.h> // For struct iovec
#define __STDC_LIMIT_MACROS
#include <stdint.h>
#endif

#include "atomic.h"


#ifdef _WIN32

extern "C"
{
  __declspec( dllimport ) void __stdcall DebugBreak();
}

struct iovec
{
  size_t iov_len;
  void* iov_base;
};

#else

static inline void DebugBreak()
{
  *((int*)0) = 0xabadcafe;
}
inline void memcpy_s( void* dest, size_t dest_size, const void* src, size_t count )
{
  memcpy( dest, src, count );
}

#ifndef __linux__
inline size_t strnlen( const char* s, size_t maxlen )
{
  return strlen( s );<commit_msg>client: yidl.h: #include rearranging for Linux<commit_after>// Copyright 2003-2009 <NAME>.
// This source comes from the yidl project. It is licensed under the GPLv2 (see COPYING for terms and conditions).

#ifndef _YIDL_H_
#define _YIDL_H_

#define __STDC_LIMIT_MACROS
#ifdef _WIN32
#include "msstdint.h"
#else
#include <sys/uio.h> // For struct iovec
#include <stdint.h>
#endif

#include "atomic.h"

#include <cstring>
#include <ostream>
#include <string>


#ifdef _WIN32

extern "C"
{
  __declspec( dllimport ) void __stdcall DebugBreak();
}

struct iovec
{
  size_t iov_len;
  void* iov_base;
};

#else

static inline void DebugBreak()
{
  *((int*)0) = 0xabadcafe;
}
inline void memcpy_s( void* dest, size_t dest_size, const void* src, size_t count )
{
  memcpy( dest, src, count );
}

#ifndef __linux__
inline size_t strnlen( const char* s, size_t maxlen )
{
  return strlen( s );
{'fraction_non_alphanumeric': 0.11728045325779037, 'fraction_numerical': 0.0169971671388102, 'mean_word_length': 4.536050156739812, 'pattern_counts': {'":': 0, '<': 15, '<?xml version=': 0, '>': 15, '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': '1692557', 'n_tokens_mistral': 709, 'n_tokens_neox': 684, 'n_words': 209}