<commit_before>//
//  Data+Extractable.swift
//  Bluejay
//
//  Created by <NAME> on 2017-05-26.
//  Copyright © 2017 Steamclock Software. All rights reserved.
//

import Foundation

extension Data {
    
    func extract<T>(start: Int, length: Int) -> T {
        return self.subdata(in: start..<start+length).withUnsafeBytes { $0.pointee }
    }
    <commit_msg>Expose the extract extension on Data<commit_after>//
//  Data+Extractable.swift
//  Bluejay
//
//  Created by <NAME> on 2017-05-26.
//  Copyright © 2017 Steamclock Software. All rights reserved.
//

import Foundation

extension Data {
    
    public func extract<T>(start: Int, length: Int) -> T {
        return self.subdata(in: start..<start+length).withUnsafeBytes { $0.pointee }
    }
    
{'fraction_non_alphanumeric': 0.13720316622691292, 'fraction_numerical': 0.03430079155672823, 'mean_word_length': 2.702439024390244, 'pattern_counts': {'":': 0, '<': 9, '<?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': '6703989', 'n_tokens_mistral': 270, 'n_tokens_neox': 245, 'n_words': 66}