<commit_before>// A current_time function for use in the tests.  Returns time in
// milliseconds.

#ifdef _WIN32
extern "C" bool QueryPerformanceCounter(uint64_t *);
extern "C" bool QueryPerformanceFrequency(uint64_t *);
double current_time() {
    uint64_t t, freq;
    QueryPerformanceCounter(&t);
    QueryPerformanceFrequency(&freq);
    return (t * 1000.0) / freq;
}
#else
#include <sys/time.h>
double current_time() {
    static bool first_call = true;<commit_msg>Fix build of tutorials that require libpng under Visual Studio.<commit_after>// A current_time function for use in the tests.  Returns time in
// milliseconds.

#ifdef _WIN32
#include <Windows.h>
double current_time() {
    LARGE_INTEGER freq, t;
    QueryPerformanceCounter(&t);
    QueryPerformanceFrequency(&freq);
    return (t.QuadPart * 1000.0) / freq.QuadPart;
}
// Gross, these come from Windows.h
#undef max
#undef min
#else
#include <sys/time.h>
double current_time() {
    static bool first_call = true;
{'fraction_non_alphanumeric': 0.10873983739837398, 'fraction_numerical': 0.02032520325203252, 'mean_word_length': 4.324324324324325, 'pattern_counts': {'":': 0, '<': 6, '<?xml version=': 0, '>': 6, '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': '7414446', 'n_tokens_mistral': 337, 'n_tokens_neox': 305, 'n_words': 97}