<commit_before>/* This Source Code Form is subject to the terms of the Mozilla Public
 * License, v. 2.0. If a copy of the MPL was not distributed with this
 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */

#![feature(box_syntax)]
#![feature(core_intrinsics)]
#![feature(custom_derive)]
#![feature(fnbox)]
#![feature(optin_builtin_traits)]
#![feature(plugin)]
#![feature(panic_handler)]
#![feature(reflect_marker)]
#![feature(step_by)]

#![plugin(heapsize_plugin, plugins, serde_macros)]

#![deny(unsafe_code)]

extern crate app_units;
extern crate backtrace;
#[allow(unused_extern_crates)]
#[macro_use]
extern crate bitflags;
extern crate deque;
extern crate euclid;
extern crate getopts;
extern crate heapsize;
extern crate ipc_channel;
#[cfg(feature = "non-geckolib")]
extern crate js;
#[allow(unused_extern_crates)]
#[macro_use]
extern crate lazy_static;
extern crate libc;
#[macro_use]
extern crate log;
extern crate num_cpus;
extern crate num_traits;
extern crate rand;
extern crate rustc_serialize;
extern crate serde;
extern crate smallvec;
extern crate string_cache;
extern crate url;

use std::sync::Arc;

pub mod cache;
#[allow(unsafe_code)]
pub mod debug_utils;
pub mod geometry;
#[allow(unsafe_code)]
pub mod ipc;
pub mod linked_list;
#[cfg(feature = "non-geckolib")]
#[allow(unsafe_code)]
pub mod non_geckolib;
#[allow(unsafe_code)]
pub mod opts;
pub mod panicking;
#[allow(unsafe_code)]
pub mod prefs;
pub mod print_tree;
#[allow(unsafe_code)]
pub mod resource_files;
#[allow(unsafe_code)]
pub mod str;
pub mod thread;
pub mod thread_state;
pub mod tid;
pub mod time;
pub mod vec;
#[allow(unsafe_code)]
pub mod workqueue;

#[allow(unsafe_code)]
pub fn breakpoint() {
    unsafe { ::std::intrinsics::breakpoint() };
}

// Workaround for lack of `ptr_eq` on Arcs...
#[inline]
pub fn arc_ptr_eq<T: 'static + Send + Sync>(a: &Arc<T>, b: &Arc<T>) -> bool {
    let a: &T = &**a;
    let b: &T = &**b;
    (a as *const T) == (b as *const T)
}<commit_msg>Remove unnecessary bounds on arc_ptr_eq.<commit_after>/* This Source Code Form is subject to the terms of the Mozilla Public
 * License, v. 2.0. If a copy of the MPL was not distributed with this
 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */

#![feature(box_syntax)]
#![feature(core_intrinsics)]
#![feature(custom_derive)]
#![feature(fnbox)]
#![feature(optin_builtin_traits)]
#![feature(plugin)]
#![feature(panic_handler)]
#![feature(reflect_marker)]
#![feature(step_by)]

#![plugin(heapsize_plugin, plugins, serde_macros)]

#![deny(unsafe_code)]

extern crate app_units;
extern crate backtrace;
#[allow(unused_extern_crates)]
#[macro_use]
extern crate bitflags;
extern crate deque;
extern crate euclid;
extern crate getopts;
extern crate heapsize;
extern crate ipc_channel;
#[cfg(feature = "non-geckolib")]
extern crate js;
#[allow(unused_extern_crates)]
#[macro_use]
extern crate lazy_static;
extern crate libc;
#[macro_use]
extern crate log;
extern crate num_cpus;
extern crate num_traits;
extern crate rand;
extern crate rustc_serialize;
extern crate serde;
extern crate smallvec;
extern crate string_cache;
extern crate url;

use std::sync::Arc;

pub mod cache;
#[allow(unsafe_code)]
pub mod debug_utils;
pub mod geometry;
#[allow(unsafe_code)]
pub mod ipc;
pub mod linked_list;
#[cfg(feature = "non-geckolib")]
#[allow(unsafe_code)]
pub mod non_geckolib;
#[allow(unsafe_code)]
pub mod opts;
pub mod panicking;
#[allow(unsafe_code)]
pub mod prefs;
pub mod print_tree;
#[allow(unsafe_code)]
pub mod resource_files;
#[allow(unsafe_code)]
pub mod str;
pub mod thread;
pub mod thread_state;
pub mod tid;
pub mod time;
pub mod vec;
#[allow(unsafe_code)]
pub mod workqueue;

#[allow(unsafe_code)]
pub fn breakpoint() {
    unsafe { ::std::intrinsics::breakpoint() };
}

// Workaround for lack of `ptr_eq` on Arcs...
#[inline]
pub fn arc_ptr_eq<T: 'static>(a: &Arc<T>, b: &Arc<T>) -> bool {
    let a: &T = &**a;
    let b: &T = &**b;
    (a as *const T) == (b as *const T)
}
{'fraction_non_alphanumeric': 0.14292916561633476, 'fraction_numerical': 0.00201663725737333, 'mean_word_length': 5.937062937062937, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 11, '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': '2321036', 'n_tokens_mistral': 1472, 'n_tokens_neox': 1430, 'n_words': 444}