<commit_before>//
//  _Random.swift
//  SwiftState
//
//  Created by <NAME> on 2015-12-05.
//  Copyright © 2015 <NAME>. All rights reserved.
//

#if os(OSX) || os(iOS) || os(watchOS) || os(tvOS)
import Darwin
#else
import Glibc
#endif

internal func _random(_ upperBound: Int) -> Int
{
    #if os(OSX) || os(iOS)
    return Int(arc4random_uniform(UInt32(upperBound)))
    #else
    return Int(random() % upperBound)
    #endif
}<commit_msg>Switched to arc4random_uniform() for random number generation on watchOS and tvOS as well.<commit_after>//
//  _Random.swift
//  SwiftState
//
//  Created by <NAME> on 2015-12-05.
//  Copyright © 2015 <NAME>. All rights reserved.
//

#if os(OSX) || os(iOS) || os(watchOS) || os(tvOS)
import Darwin
#else
import Glibc
#endif

internal func _random(_ upperBound: Int) -> Int
{
    #if os(OSX) || os(iOS) || os(watchOS) || os(tvOS)
    return Int(arc4random_uniform(UInt32(upperBound)))
    #else
    return Int(random() % upperBound)
    #endif
}
{'fraction_non_alphanumeric': 0.15752032520325204, 'fraction_numerical': 0.031504065040650404, 'mean_word_length': 3.436936936936937, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 9, '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': '7280444', 'n_tokens_mistral': 385, 'n_tokens_neox': 353, 'n_words': 98}