text stringlengths 2.5k 6.39M | kind stringclasses 3
values |
|---|---|
use super::constants::*;
use super::adjust_tool::*;
use super::adjust_control_point::*;
use super::super::select::*;
use crate::tools::*;
use crate::model::*;
use crate::style::*;
use flo_canvas::*;
use flo_binding::*;
use flo_animation::*;
use futures::prelude::*;
use std::f32;
use std::sync::*;
use std::collect... | the_stack |
extern crate bddisasm_sys as ffi;
use std::fmt;
/// Describes an address operand.
#[derive(Copy, Clone, Eq, PartialEq, Hash, Debug)]
pub struct OpAddr {
/// The ID of the base segment selector.
///
/// `ES` = 0, `CS` = 1, `SS` = 2, `DS` = 3, `FS` = 4, `GS` = 5.
pub base_seg: u16,
/// Offset insid... | the_stack |
feature = "fn_traits",
feature(proc_macro_hygiene, stmt_expr_attributes, type_ascription)
)]
#![cfg_attr(feature = "generator_trait", feature(generator_trait))]
#![cfg_attr(feature = "fn_traits", feature(fn_traits, unboxed_closures))]
#![cfg_attr(feature = "trusted_len", feature(trusted_len))]
#![cfg_attr(not(featu... | the_stack |
use super::{ZERO_ALLOC, Error};
use arch::memory::addresses;
// Curse no CTFE
//const HEADERS_SIZE: usize = ::core::mem::size_of::<HeapHead>() + ::core::mem::size_of::<HeapFoot>();
const MAGIC: u32 = 0x71ff11A1;
// TODO: Store the limits in the definition
pub struct HeapDef
{
start: *mut HeapHead,
last_foot: *mut H... | the_stack |
pub use crate::{
api::{
frame::{
AddScriptTagBuilder, CheckBuilder, ClickBuilder, DblClickBuilder, FillBuilder,
GotoBuilder, HoverBuilder, PressBuilder, SelectOptionBuilder, SetContentBuilder,
SetInputFilesBuilder, TapBuilder, TypeBuilder, UncheckBuilder, WaitForFunctionB... | the_stack |
use std::ops::Deref;
use std::collections::hash_map::DefaultHasher;
use std::hash::{Hash, Hasher};
use soa_derive::soa_zip;
use crate::{Particle, ParticleVec, ParticleSlice, ParticleSliceMut};
use crate::{Bonding, UnitCell};
use crate::Vector3D;
/// A molecule hash allow to identify a molecule from its atoms and bon... | the_stack |
use super::DeviceMap;
use crate::device_plugin_api::v1beta1::{
device_plugin_client::DevicePluginClient, AllocateRequest, AllocateResponse, Device, Empty,
ListAndWatchResponse, RegisterRequest,
};
use std::collections::HashMap;
use std::sync::Arc;
use tokio::sync::{broadcast, RwLock};
use tonic::Request;
use tr... | the_stack |
use engine::asset::{Asset, AssetError, AssetSystem, FileFuture, Resource};
use engine::render::{Material, Mesh, MeshBuffer, MeshData};
use std::borrow::Cow;
use std::path::Path;
use math::*;
use obj;
use obj::SimplePolygon;
use std::collections::HashMap;
use std::io::BufReader;
use std::rc::Rc;
use future... | the_stack |
use std::time::{SystemTime};
use std::time::UNIX_EPOCH;
use ecp::ECP;
use fp2::FP2;
use ecp2::ECP2;
use fp4::FP4;
use fp12::FP12;
use big::BIG;
use rand::RAND;
use hash256::HASH256;
use hash384::HASH384;
use hash512::HASH512;
use pair;
use rom;
/* MPIN API Functions */
/* Configure mode of operation */
pub const PE... | the_stack |
mod book;
mod borrow;
mod iteration;
#[cfg(feature = "serde1")]
mod serde;
mod workload;
use std::iter::Sum;
use shipyard::*;
#[derive(PartialEq, Eq, Debug, Clone, Copy)]
struct USIZE(usize);
impl Component for USIZE {
type Tracking = track::Untracked;
}
impl Sum for USIZE {
fn sum<I: Iterator<Item = Self>>... | the_stack |
use whitebox_lidar::*;
use crate::tools::*;
use std;
use std::env;
use std::fs::DirBuilder;
use std::io::{Error, ErrorKind};
use std::path;
use std::path::Path;
/// This tool can be used to break a LiDAR LAS file into multiple, non-overlapping tiles, each saved as a
/// single LAS file. The user must specify the param... | the_stack |
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq)]
pub struct SingleMasterConfiguration {
/// <p>The period of time a signaling channel retains underlivered messages before they are discarded.</p>
pub message_ttl_seconds: std::option::Option<i32>,
}
impl SingleMasterConfiguration {
/// <p>T... | the_stack |
use im;
use moniker::{Binder, Embed, FreeVar, Var};
use num_bigint::BigInt;
use std::io;
use crate::semantics::{nf_term, Context, Definition, InternalError};
use crate::syntax::core;
use crate::syntax::Label;
#[derive(Debug)]
pub enum ParseError {
InvalidType(core::RcType),
InvalidValue(core::RcValue),
In... | the_stack |
use log::{debug, info, warn};
use std::collections::{HashMap, HashSet};
use std::fs;
use std::path::{Path, PathBuf};
use std::process;
use std::str::FromStr;
use std::sync::{mpsc::Sender, Arc, Mutex};
use std::thread;
use std::time::{Duration, Instant};
use serde::{de::DeserializeOwned, Serialize};
use url::Url;
use w... | the_stack |
use std::iter;
use winapi::{
shared::{dxgi1_2, dxgiformat},
um::{d3d12, d3dcommon},
};
pub(super) fn map_texture_format(format: wgt::TextureFormat) -> dxgiformat::DXGI_FORMAT {
use wgt::TextureFormat as Tf;
use winapi::shared::dxgiformat::*;
match format {
Tf::R8Unorm => DXGI_FORMAT_R8_UNO... | the_stack |
use std::collections::HashMap;
use std::hash::BuildHasherDefault;
use crossfont::{
Error as RasterizerError, FontDesc, FontKey, GlyphKey, Metrics, Rasterize, RasterizedGlyph,
Rasterizer, Size, Slant, Style, Weight,
};
use fnv::FnvHasher;
use log::{error, info};
use unicode_width::UnicodeWidthChar;
use crate::... | the_stack |
use std::collections::HashSet;
use std::fs::OpenOptions;
use std::path::Path;
use std::sync::atomic::Ordering;
use anyhow::{bail, Context, Result};
use rafs::metadata::{RafsMode, RafsSuper};
use serde::Serialize;
use crate::core::chunk_dict::{ChunkDict, HashChunkDict};
use crate::core::tree::Tree;
#[derive(Copy, Clo... | the_stack |
use glib::object::Cast;
use glib::object::IsA;
use glib::signal::connect_raw;
use glib::signal::SignalHandlerId;
use glib::translate::*;
use std::boxed::Box as Box_;
use std::fmt;
use std::mem::transmute;
glib::wrapper! {
#[doc(alias = "GtkAccelGroup")]
pub struct AccelGroup(Object<ffi::GtkAccelGroup, ffi::Gtk... | the_stack |
#![no_std]
#![feature(trait_alias)]
extern crate log;
extern crate alloc;
extern crate spin;
extern crate irq_safety;
extern crate serial_port_basic;
use log::{Record, Level, SetLoggerError, Metadata, Log};
use core::{borrow::Borrow, fmt::{self, Write}, ops::Deref};
use spin::Once;
use irq_safety::MutexIrqSafe;
use s... | the_stack |
mod utils;
use clap::{App, AppSettings, Arg, ErrorKind};
#[test]
fn flag_subcommand_normal() {
let matches = App::new("test")
.subcommand(
App::new("some").short_flag('S').long_flag("some").arg(
Arg::new("test")
.short('t')
.long("test")
... | the_stack |
//! Messages used for NDP (ICMPv6).
use core::num::NonZeroU8;
use core::time::Duration;
use net_types::ip::{Ipv6, Ipv6Addr};
use zerocopy::{AsBytes, ByteSlice, FromBytes, Unaligned};
use crate::icmp::{IcmpIpExt, IcmpPacket, IcmpUnusedCode};
use crate::utils::NonZeroDuration;
use crate::{U16, U32};
/// An ICMPv6 pac... | the_stack |
use glib::error::ErrorDomain;
use glib::translate::*;
use glib::value::FromValue;
use glib::value::ToValue;
use glib::Quark;
use glib::StaticType;
use glib::Type;
use std::ffi::CStr;
use std::fmt;
#[derive(Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Clone, Copy)]
#[non_exhaustive]
#[doc(alias = "GstPlayerColorBalance... | the_stack |
use log::LevelFilter;
use openssl::ssl::{SslConnector, SslMethod, SslVerifyMode};
use postgres::{fallible_iterator::FallibleIterator, Client};
use postgres_openssl::MakeTlsConnector;
use rand::{distributions::Alphanumeric, thread_rng, Rng};
use state_map::StateMap;
use std::{borrow::Cow, collections::BTreeMap, env, fmt... | the_stack |
use anyhow::Context;
use anyhow::*;
use cgmath::InnerSpace;
use lifeguard::*;
use std::{
collections::{HashMap, VecDeque},
};
use crate::rendering::gpu_resources::GpuResources;
use super::mesh_builder;
use super::{
chunk::Chunk,
rendering::voxel_rendering::{self},
};
use super::{
chunk::{ChunkMesh, Lo... | the_stack |
use crate::xetex_font_manager::AddToMaps;
use std::collections::VecDeque;
use crate::xetex_font_manager::AddToList;
use crate::xetex_font_manager::FontMgrExt;
use std::ffi::{CStr, CString};
use std::ptr;
use objc::rc::autoreleasepool;
use objc::runtime::Object;
use objc_foundation::{NSArray, NSEnumerator, NSString};... | the_stack |
use std::borrow::Cow;
use std::boxed::Box;
use std::collections::HashMap;
use std::ffi::c_void;
use std::os::raw::c_char;
use std::sync::atomic::AtomicBool;
use std::sync::atomic::AtomicPtr;
use std::sync::atomic::Ordering;
use std::sync::Arc;
use std::sync::Mutex;
use std::sync::Weak;
use std::time::SystemTime;
use c... | the_stack |
use crate::prelude::*;
use crate as frp;
use crate::data::bitfield::BitField;
use crate::data::bitfield::BitField32;
use nalgebra::Vector2;
// ==============
// === Button ===
// ==============
/// An enumeration representing the mouse buttons. Please note that we do not name the buttons
/// left, right, and midd... | the_stack |
use super::{compile_bin, compile_doc, compile_lib, context::BuildContext, Target, Targets};
use crate::{
retrieve::cache::{Binary, BuildHash, OutputLayout, Source},
util::{
clear_dir,
error::Result,
fmt_multiple,
graph::Graph,
lock::DirLock,
shell::{Shell, Verbosi... | the_stack |
use crate::protocol::PartyIndex;
use thiserror::Error;
pub use super::messages::resharing::{InMsg, Message, OutMsg, Phase1Broadcast};
use crate::ecdsa::messages::SecretShare;
use curv::{BigInt, FE};
use serde::{Deserialize, Serialize};
use std::collections::{BTreeSet, HashMap};
use std::fmt::Debug;
use trace::trace... | the_stack |
use std::collections::{HashMap, HashSet};
use std::hash::Hash;
use std::iter::FromIterator;
use indexmap::map::IndexMap;
use itertools::Itertools;
use ndarray::prelude::*;
use noisy_float::prelude::n64;
use crate::{base, Float, proto, Warnable};
use crate::base::{IndexKey, NodeProperties, Release, SensitivitySpace, V... | the_stack |
use std::collections::HashMap;
use std::hash::{BuildHasher, Hash};
use kvdb::KeyValueDB;
use chain_core::state::account::{StakedState, StakedStateAddress};
use crate::Storage;
pub trait Get {
type Key;
type Value;
fn get(&self, key: &Self::Key) -> Option<Self::Value>;
}
pub trait SimpleStore: Get {
... | the_stack |
use core::cell::Cell;
use kernel::hil;
use kernel::hil::i2c::{self, Error, I2CHwMasterClient, I2CMaster};
use kernel::platform::chip::ClockInterface;
use kernel::utilities::cells::{OptionalCell, TakeCell};
use kernel::utilities::registers::interfaces::{ReadWriteable, Readable, Writeable};
use kernel::utilities::regist... | the_stack |
use std::collections::BTreeMap;
use compressor_integration_tests::{
add_contents_to_database, database_collapsed_states_match_map, database_structure_matches_map,
empty_database,
map_builder::{
compressed_3_3_from_0_to_13_with_state, line_segments_with_state, line_with_state,
structure_from... | the_stack |
use prolog_parser::ast::*;
use prolog_parser::clause_name;
use crate::clause_types::*;
use crate::fixtures::*;
use crate::forms::*;
use crate::instructions::*;
use crate::machine::code_repo::CodeRepo;
use crate::machine::heap::*;
use crate::machine::machine_state::*;
use crate::machine::partial_string::*;
use crate::m... | the_stack |
use crate::cipher_suite::{
HeaderProtectionKey, HeaderProtectionKeys, OneRttKey, PacketKey, PacketKeys,
};
use bytes::Bytes;
use core::{fmt, fmt::Debug, task::Poll};
use rustls::{
quic::{self, QuicExt},
Connection,
};
use s2n_quic_core::{
application::ServerName,
crypto::{self, tls, CryptoError},
... | the_stack |
use crate::dynamics::solver::DeltaVel;
use crate::dynamics::{
GenericJoint, IntegrationParameters, JointGraphEdge, JointIndex, JointParams, RigidBody,
};
use crate::math::{AngularInertia, Dim, Isometry, Real, Rotation, SpacialVector, Vector, DIM};
use crate::na::UnitQuaternion;
use crate::parry::math::{AngDim, Spat... | the_stack |
use super::super::State;
use super::{
assert_error, connect, connect_force_idle, default_client, default_server, maybe_authenticate,
new_client, new_server, send_something, DEFAULT_STREAM_DATA,
};
use crate::events::ConnectionEvent;
use crate::recv_stream::RECV_BUFFER_SIZE;
use crate::send_stream::{SendStreamSt... | the_stack |
use super::{
error::{Error, Result},
message::*,
Config,
};
use crate::{
constants::*,
driver::DecodeMode,
events::{internal_data::*, CoreContext},
};
use audiopus::{
coder::Decoder as OpusDecoder,
error::{Error as OpusError, ErrorCode},
Channels,
};
use discortp::{
demux::{self,... | the_stack |
pub const NMI_VECTOR: u16 = 0xFFFA;
pub const RESET_VECTOR: u16 = 0xFFFC;
pub const IRQ_VECTOR: u16 = 0xFFFE;
const STACK_PAGE: u16 = 0x0100;
pub enum IrqInterrupt {
IRQ,
None,
}
impl IrqInterrupt {
pub fn or(self, other: IrqInterrupt) -> IrqInterrupt {
match self {
IrqInt... | the_stack |
use std::collections::HashMap;
use std::env;
use std::io::{self, ErrorKind};
use std::sync::{
atomic::{AtomicUsize, Ordering},
Arc,
};
use futures::SinkExt;
use futures::StreamExt;
use serde::{Deserialize, Serialize};
use slog::{debug, error, info, o, Drain, Logger};
use tokio::io::{AsyncReadExt, AsyncWriteExt... | the_stack |
use crate::cfg::Configuration;
use crate::core::{
cache::Cache,
message_app::{CreateMessageApp, CreateMessageEndpoint},
types::{EndpointHeaders, EndpointSecret, MessageAttemptTriggerType, MessageId, MessageStatus},
};
use crate::db::models::{message, messageattempt, messagedestination};
use crate::error::{E... | the_stack |
extern crate rocksdb;
extern crate uuid;
extern crate varint;
use self::uuid::Uuid;
use std::cmp::Ordering;
use std::collections::{BTreeMap, HashSet};
use std::io::Cursor;
use std::io::Write;
use std::mem;
use std::str;
use std::sync::{LockResult, Mutex, MutexGuard};
use self::varint::{VarintRead, VarintWrite};
pub... | the_stack |
use crate::globe::chunk_pair::PointPair;
use crate::globe::ChunkOrigin;
use crate::globe::{chunks_containing_point, origin_of_chunk_owning};
use crate::grid::{GridCoord, Point3, PosInOwningRoot};
use specs;
#[derive(PartialEq, Eq, Copy, Clone, Debug)]
pub enum Material {
Air,
Dirt,
Water,
}
// TODO: we sh... | the_stack |
#[macro_use] extern crate bitflags;
// use core::cell::RefCell;
// TODO: use these tables and tips:
// https://sourceforge.net/p/oszur11/code/ci/master/tree/Chapter_06_Shell/04_Makepp/arch/i386/arch/devices/i8042.c
// TODO: seems like we actually can use phf crates
// we can use the "core" feature enables libcore in... | the_stack |
use bulletproofs::r1cs;
use core::iter;
use core::iter::FromIterator;
use curve25519_dalek::ristretto::CompressedRistretto;
use curve25519_dalek::scalar::Scalar;
use merlin::Transcript;
use musig::{BatchVerification, Signature};
use spacesuit;
use spacesuit::BitRange;
use std::mem;
use crate::constraints::{Commitment,... | the_stack |
use self::Destination::*;
use super::{
snippet::{Annotation, AnnotationType, Line, MultilineAnnotation, Style, StyledString},
styled_buffer::StyledBuffer,
CodeSuggestion, DiagnosticBuilder, DiagnosticId, Level, SourceMapperDyn, SubDiagnostic,
};
use crate::{
sync::Lrc,
syntax_pos::{MultiSpan, Source... | the_stack |
use super::import_export_dtos::*;
use diesel::prelude::*;
use projectpadsql::models::{
EnvironmentType, Project, ProjectNote, ProjectPointOfInterest, Server, ServerDatabase,
ServerExtraUserAccount, ServerLink, ServerNote, ServerPointOfInterest, ServerWebsite,
};
use projectpadsql::sqlite_is;
use regex::Regex;
u... | the_stack |
use std::convert::{TryFrom, TryInto};
use std::{
os::raw::{c_int, c_void},
ptr, slice,
};
use super::{function::Result, Function};
use crate::errors::Error;
pub use tvm_sys::{ffi, ArgValue, RetValue};
/// A trait representing whether the function arguments
/// and return type can be assigned to a TVM packed ... | the_stack |
use crate::chunk::{File, Line};
use crate::printer::{Printer, PrinterOptions, TermColorSupport, TextWrapMode};
use ansi_colours::ansi256_from_rgb;
use anyhow::Result;
use flate2::read::ZlibDecoder;
use memchr::{memchr_iter, Memchr};
use std::cmp;
use std::ffi::OsStr;
use std::fmt;
use std::io::{self, Stdout, StdoutLock... | the_stack |
use crate::{Address, Properties, Update, UpdateResult, WatcherOperationError};
use fidl_fuchsia_net as fnet;
use fidl_fuchsia_net_interfaces as fnet_interfaces;
use futures::{Stream, TryStreamExt};
use net_types::{LinkLocalAddress as _, ScopeableAddress as _};
use std::collections::{HashMap, HashSet};
use thiserror::E... | the_stack |
use crate::configuration::{generate_config_schema, ConfigurationError};
use crate::router::ApolloRouter;
use crate::router::ConfigurationKind;
use crate::router::SchemaKind;
use crate::router::ShutdownKind;
use crate::{
configuration::Configuration,
subscriber::{set_global_subscriber, RouterSubscriber},
};
use ... | the_stack |
use core::mem;
use core::sync::atomic::{AtomicBool, Ordering};
use crate::device::cpu::registers::{control_regs, tlb};
use crate::syscall::FloatRegisters;
/// This must be used by the kernel to ensure that context switches are done atomically
/// Compare and exchange this to true when beginning a context switch on an... | the_stack |
//! Transaction validation.
extern crate alloc;
use alloc::{format, vec::Vec};
use super::error::{TransactionValidationError, TransactionValidationResult};
use crate::{
constants::*,
membership_proofs::{derive_proof_at_index, is_membership_proof_valid},
tx::{Tx, TxOut, TxOutMembershipProof, TxPrefix},
... | the_stack |
extern crate kdtree;
use whitebox_common::algorithms::{
interior_point, is_clockwise_order, point_in_poly, poly_in_poly, polygon_area,
};
use whitebox_common::structures::{BoundingBox, Point2D, Polyline};
use crate::tools::*;
use whitebox_vector::*;
use kdtree::distance::squared_euclidean;
use kdtree::KdTree;
use ... | the_stack |
use std::alloc::{Layout, Global, handle_alloc_error, dealloc, alloc_zeroed};
use std::sync::atomic::{AtomicBool,Ordering};
use std::thread::{JoinHandle,self};
use std::sync::{Once, ONCE_INIT};
use std::ptr::NonNull;
use std::{ptr,mem};
use std::cell::UnsafeCell;
use pleco::MoveList;
use pleco::tools::pleco_arc::Arc;
u... | the_stack |
//! `Renderer` owns the JavaScript Custom Element plugin, as well as
//! associated state such as column restrictions and `plugin_config`
//! (de-)serialization.
//!
//! `Renderer` wraps a smart pointer and is meant to be shared among many
//! references throughout the application.
mod activate;
mod limits;
mod plugin... | the_stack |
use std::cmp::Ordering;
use std::fmt::{self, Display};
use ansi_term::Colour::{Cyan, Yellow};
use rover_client::shared::GraphRef;
use crate::utils::env::RoverEnvKey;
use serde::Serialize;
/// `Suggestion` contains possible suggestions for remedying specific errors.
#[derive(Serialize, Debug)]
pub enum Suggestion {
... | the_stack |
use crate::{
bindings::{
kernel::{itimerval, setitimer, user_desc, ITIMER_REAL},
ptrace::{PTRACE_EVENT_EXIT, PTRACE_INTERRUPT},
},
kernel_abi::{syscall_instruction_length, syscall_number_for_gettid, SupportedArch},
kernel_metadata::syscall_name,
log::LogLevel::{LogDebug, LogWarn},
... | the_stack |
extern crate chrono;
extern crate fix_rs;
extern crate mio;
use mio::{Events,Poll,PollOpt,Ready,Token};
use mio::tcp::{TcpListener,TcpStream};
use mio::unix::UnixReady;
use std::any::Any;
use std::collections::HashMap;
use std::net::{Ipv4Addr,SocketAddr,SocketAddrV4};
use std::io::Read;
use std::sync::atomic::{AtomicU... | the_stack |
mod rosomaxa_test;
use super::*;
use crate::algorithms::gsom::*;
use crate::algorithms::nsga2::Objective;
use crate::algorithms::statistics::relative_distance;
use crate::construction::heuristics::*;
use crate::models::problem::ObjectiveCost;
use crate::solver::RefinementSpeed;
use crate::utils::{Environment, Random};... | the_stack |
#![allow(unused_imports, dead_code)]
use std::ops::{Deref, DerefMut};
use futures::{Future, Poll, Async};
use core::{self, OclPrm, Mem as MemCore, MemMap as MemMapCore,
MemFlags, MapFlags, ClNullEventPtr, ClWaitListPtr, AsMem};
use standard::{Event, EventList, Queue, Buffer, ClWaitListPtrEnum, ClNullEventPtrEnum};... | the_stack |
use crate::dataflow::StepId;
use crate::pyo3_extensions::StateKey;
use pyo3::exceptions::PyValueError;
use rdkafka::admin::AdminClient;
use rdkafka::admin::AdminOptions;
use rdkafka::admin::NewTopic;
use rdkafka::admin::TopicReplication;
use rdkafka::consumer::Consumer;
use rdkafka::consumer::StreamConsumer;
use rdkafk... | the_stack |
use crate::clang::{Clang, Node};
use crate::syntax::attrs::OtherAttrs;
use crate::syntax::namespace::Namespace;
use crate::syntax::report::Errors;
use crate::syntax::{Api, Discriminant, Doc, Enum, EnumRepr, ForeignName, Pair, Variant};
use flate2::write::GzDecoder;
use memmap::Mmap;
use proc_macro2::{Delimiter, Group, ... | the_stack |
pub mod pac {
// The nRF5340 has a secure and non-secure (NS) mode.
// To avoid cfg spam, we remove _ns or _s suffixes here.
pub use nrf5340_app_pac::{
interrupt,
Interrupt,
Peripherals,
cache_s as cache,
cachedata_s as cachedata,
cacheinfo_s as cacheinfo,
... | the_stack |
mod sys_common;
use cap_fs_ext::DirExt;
use cap_std::ambient_authority;
use cap_std::fs::Dir;
use sys_common::io::tmpdir;
use sys_common::symlink_supported;
#[test]
fn basic_symlinks() {
if !symlink_supported() {
return;
}
let tmpdir = tmpdir();
check!(tmpdir.create("file"));
check!(tmpd... | the_stack |
use core::convert::TryInto;
use core::ops::Deref;
use crate::error::TryFromParsed;
use crate::format_description::well_known::{Rfc2822, Rfc3339};
use crate::format_description::FormatItem;
use crate::parsing::{Parsed, ParsedItem};
use crate::{error, Date, Month, OffsetDateTime, PrimitiveDateTime, Time, UtcOffset, Week... | the_stack |
use crate::hashiter::{Iter, IterMut, OwnedIter};
use crate::util::{allocate, deallocate, round_to_pow2, AllocationKind};
use crate::{make_hash, Value};
use core::alloc::Allocator;
use core::{
borrow::Borrow,
default::Default,
hash::{BuildHasher, BuildHasherDefault, Hash, Hasher},
};
use std::alloc::Global;
... | the_stack |
// Provide known mount-points of dependency crates.
#[doc(hidden)]
pub use core;
#[doc(hidden)]
pub use funty;
#[doc(hidden)]
#[macro_export]
#[doc = include_str!("../../doc/macros/encode_bits.md")]
macro_rules! __encode_bits {
/* ENTRY POINTS
*
* These arms match the syntax provided by the public macros, and ... | the_stack |
// https://github.com/rust-lang/rust-clippy/issues/702
#![allow(unknown_lints)]
#![allow(clippy::all)]
#![allow(unused_attributes)]
#![cfg_attr(rustfmt, rustfmt::skip)]
#![allow(box_pointers)]
#![allow(dead_code)]
#![allow(missing_docs)]
#![allow(non_camel_case_types)]
#![allow(non_snake_case)]
#![allow(non_upper_cas... | the_stack |
//! Explicit stack slots, which can be used for stack emplacement.
//!
//! A [`Slot`] is uninitialized storage on the stack that can be manipulated
//! explicitly. Notionally, a [`Slot<T>`] represents a `let x: T;` in some
//! function's stack.
//!
//! [`Slot`]s mut be created with the [`slot!()`] macro:
//! ```
//! # ... | the_stack |
use std::{borrow::BorrowMut, fmt, mem};
use super::*;
pub(super) struct ScanFnInput<'a, 'scan> {
/**
The complete raw input buffer
*/
pub(super) input: &'scan [u8],
/**
The offset of the current character in the input buffer.
This isn't necessarily the same as the `input_offset` on `Scan`... | the_stack |
use bumpalo::Bump;
use libeir_ir::pattern::{PatternClause, PatternContainer, PatternNode};
use libeir_ir::FunctionBuilder;
use libeir_ir::{BasicType, Block, Value};
use libeir_util_pattern_compiler::{CfgNodeKind, EdgeRef, NodeIndex, PatternCfg};
use libeir_diagnostics::SourceSpan;
use super::erlang_pattern_provider... | the_stack |
use crate::errors::InvalidValue;
use crate::{
value::{Decimal, Value},
Encoding, Error, Ident, Result,
};
use core::{
convert::{TryFrom, TryInto},
fmt::{self, Debug, Write},
iter::FromIterator,
str::{self, FromStr},
};
/// Individual parameter name/value pair.
pub type Pair<'a> = (Ident<'a>, Va... | the_stack |
use mio::{Evented, Poll, PollOpt};
use pnet::packet::tcp::TcpPacket;
use bufferable_ssl::BufferableSSL;
use buffered_tunnel::BufferedTunnel;
use evented_ssl_eavesdropper::EventedSSLEavesdropper;
use protocol_outer_framing::{OuterFrameMsgAssembler, ReadMsgRes};
use session_error::SessionError;
use signalling::{ClientTo... | the_stack |
// NOTE: the compiler claims this is unused, but that's a lie and removing this line will cause
// compilation to fail
#[allow(unused_imports)]
use assert_cmd::prelude::*;
use predicates::prelude::*;
use timebomb;
use std::process::Command;
const NAME: &str = "sh";
const PIPELINE: &str = "pipeline";
const PIPEL... | the_stack |
use std::mem::{replace, size_of, size_of_val};
use std::collections::{HashMap, VecDeque};
use std::collections::vec_deque::Iter as VecDequeIter;
use num::{Float};
use serialize::json::{Json, ToJson};
use values::Value as TipValue;
use super::deltabuf::{DeltaBuf, DeltaIter, Delta, Int};
use Key;
#[derive(Debug)]
pub ... | the_stack |
pub mod control_block;
pub mod log_var;
use std::collections::BTreeMap;
use std::collections::btree_map::Entry::*;
use std::mem;
use std::sync::Arc;
use std::any::Any;
use std::cell::Cell;
use self::log_var::LogVar;
use self::log_var::LogVar::*;
use self::control_block::ControlBlock;
use super::tvar::{TVar, VarContro... | the_stack |
#[macro_use]
extern crate proc_macro_hack;
#[macro_use]
extern crate quote;
use std::mem;
use std::os::raw::c_void;
use std::string::String;
use quote::{Tokens, Ident};
proc_macro_expr_impl! {
pub fn structure_impl(input: &str) -> String {
let format = trim_quotes(input);
let struct_name = Ident::... | the_stack |
// rustc warnings
#![warn(unused)]
#![warn(missing_debug_implementations)]
#![allow(unused_unsafe)]
#![allow(unreachable_code)]
#![allow(dead_code)]
#![cfg_attr(test, allow(unused_imports))]
// rustdoc warnings
#![warn(missing_docs)] // hopefully this will soon become deny(missing_docs)
#![deny(intra_doc_link_resoluti... | the_stack |
macro_rules! interm {
($n: expr) => {
ArithmeticTerm::Interm($n)
};
}
/* A simple macro to count the arguments in a variadic list
* of token trees.
*/
macro_rules! count_tt {
() => { 0 };
($odd:tt $($a:tt $b:tt)*) => { (count_tt!($($a)*) << 1) | 1 };
($($a:tt $even:tt)*) => { count_tt!($(... | the_stack |
extern crate mio;
use std::process;
use std::error::Error;
use std::sync::Arc;
use network::tcp::TcpConnection;
use network::{NetworkCommand, NetworkCMD, Slab, CONNECTION_COUNT_PRE_ALLOC, ConnectionIdentity, SocketType, Connection};
use node::{NET_RECEIVER_CHANNEL_TOKEN, EVENT_LOOP_EVENTS_SIZE};
use event::Event;
use... | the_stack |
use crate::HirLocation;
use crate::TypeChecker;
use crate::TypeCheckerFamily;
use crate::TypeCheckerFamilyDependentExt;
use crate::TypeCheckerVariableExt;
use crate::UniverseBinder;
use lark_entity::Entity;
use lark_entity::EntityData;
use lark_entity::LangItem;
use lark_error::{Diagnostic, ErrorReported};
use lark_hir... | the_stack |
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
// https://www.apache.org/licenses/LICENSE-2.0
// Unless required by applicable law or agreed to in writing, software
// distributed und... | the_stack |
use num_traits::{Float, NumCast};
use super::{Approximation, Curve};
/// Cubic Bezier curve that is scaled to the given domain and range.
#[derive(Copy, Clone)]
pub struct Bezier<T>
where
T: Float,
{
/// This is the start coordinate of the range of the Bezier curve.
pub from_value: T,
/// This is the... | the_stack |
extern crate test;
use std::collections::VecDeque;
use std::thread::{self, Thread};
use std::time::Duration;
use std::sync::{Arc, Mutex};
use std::str::FromStr;
use futures::{Stream, Canceled};
use futures::sync::mpsc::{unbounded, UnboundedSender, UnboundedReceiver};
use futures::Future;
use futures::sync::oneshot::{... | the_stack |
#[macro_use]
extern crate lazy_static;
use std::{
fs,
io::{self, prelude::*},
num, path,
sync::{
atomic::{AtomicBool, Ordering},
Arc,
},
thread, time,
};
use byteorder::{NativeEndian, WriteBytesExt};
use sysctl::Sysctl;
use bpfstructs::BpfStruct;
use lockc_uprobes::{add_contai... | the_stack |
use DomNode;
use keys::KeyIter;
/// `Updater`s modify the current application state based on messages.
pub trait Updater<State, Message>: Sized {
/// Modify the application state based on a message.
///
/// `KeyIter` may be used to identify which component the message originated from.
fn update(&self, ... | the_stack |
mod csv;
mod find;
mod input;
mod ui;
#[allow(dead_code)]
mod util;
mod view;
use crate::input::{Control, InputHandler};
use crate::ui::{CsvTable, CsvTableState, FinderState};
extern crate csv as sushi_csv;
use anyhow::{bail, Context, Result};
use clap::Parser;
use regex::Regex;
use std::convert::TryInto;
use std::fs... | the_stack |
use std::convert::Infallible;
use std::fmt;
use std::pin::Pin;
use std::task::Poll;
use heph::actor;
use heph::actor_ref::{ActorGroup, Delivery};
use heph::rt::ThreadLocal;
use heph::test::{init_local_actor, poll_actor, poll_future};
use crate::util::{assert_send, assert_size, assert_sync};
#[test]
fn size() {
a... | the_stack |
use std::convert::TryFrom;
use wasminspect_vm_macro::TryFromWasmParserOperator;
use wasmparser::*;
#[derive(Debug, Clone)]
pub struct Instruction {
pub kind: InstructionKind,
pub offset: usize,
}
#[derive(Debug, Clone)]
pub struct BrTableData {
pub table: Vec<u32>,
pub default: u32,
}
trait WasmInstPa... | the_stack |
use crate::reactors::ReactorDefinition;
use crate::workflows::definitions::{WorkflowDefinition, WorkflowStepDefinition, WorkflowStepType};
use pest::iterators::{Pair, Pairs};
use pest::Parser;
use std::collections::HashMap;
use std::time::Duration;
use thiserror::Error;
use tracing::warn;
/// Configuration for a Mmids... | the_stack |
//! Library of macros and functions for FFI of VCL solution, targeting
//! Java-compatible architectures (including Android).
extern crate jni;
#[macro_use]
extern crate wedpr_ffi_macros;
use jni::{
objects::{JClass, JObject, JString, JValue},
sys::{jlong, jobject},
JNIEnv,
};
use protobuf::{self, Messag... | the_stack |
use std::fmt::Debug;
use std::rc::Rc;
use itertools::{EitherOrBoth, Itertools};
use js_sys::Reflect;
use wasm_bindgen::prelude::*;
use wasm_bindgen::JsCast;
use web_sys::{self, Document, HtmlElement, Node};
use crate::{
html::{Attribute, EventToMessage, Html, HtmlTag, PropertyValue},
program::Program,
};
pub... | the_stack |
use std::str::FromStr;
// External deps
use lazy_static::lazy_static;
use zksync_basic_types::{AccountId, Address, TokenId};
// Workspace deps
use crate::{
franklin_crypto::{alt_babyjubjub::AltJubjubBn256, rescue::bn256::Bn256RescueParams},
merkle_tree::rescue_hasher::BabyRescueHasher,
};
/// Depth of the acco... | the_stack |
use std::{
collections::HashSet,
sync::{
atomic::{AtomicBool, Ordering},
Arc, Mutex,
},
};
use anyhow;
use futures::{
channel::{mpsc, oneshot},
prelude::*,
};
use io_context::Context;
use thiserror::Error;
use tokio;
use oasis_core_runtime::{
cbor,
common::sgx::avr::Enclave... | the_stack |
use core;
use safecast::SafeCast;
use core::sync::atomic::{AtomicUsize, Ordering};
use rangeset::{Range, RangeSet};
const MAX_APICS: usize = 300;
const MAX_NODES: usize = 16;
static NUM_CORES: AtomicUsize = AtomicUsize::new(0);
static mut APICS: [Option<ApicInfo>; MAX_APICS] = [None; MAX_APICS];
static mut NODES: [O... | the_stack |
extern crate libc;
// TODO: Put this somewhere common, can't load `loader` here
#[derive(Debug)]
pub enum Error
{
NotFound,
NotExecutable,
BadFormat,
CorruptExecutable,
BadArguments,
}
#[allow(improper_ctypes_definitions)]
#[no_mangle]
pub extern "C" fn new_process(executable_handle: ::syscalls::vfs::File, proce... | the_stack |
use failure::Fail;
use glob::Pattern as GlobPattern;
use glob::{self, MatchOptions};
use std::borrow::Cow;
use std::cell::RefCell;
use std::ffi::{OsStr, OsString};
use std::fmt;
use std::fs::{File, OpenOptions};
use std::io::{Read, Write};
use std::iter::FromIterator;
use std::os::unix::ffi::{OsStrExt, OsStringExt};
u... | the_stack |
#![warn(missing_docs, missing_debug_implementations, rust_2018_idioms)]
use std::cell::{Cell, UnsafeCell};
use std::fmt;
use std::future::Future;
use std::mem::{self, ManuallyDrop};
use std::ops::{Deref, DerefMut};
use std::panic::{RefUnwindSafe, UnwindSafe};
use std::pin::Pin;
use std::ptr::{self, NonNull};
use std::... | the_stack |
use nalgebra::DMatrix;
use nalgebra_sparse::csr::CsrMatrix;
use nalgebra_sparse::{SparseEntry, SparseEntryMut, SparseFormatErrorKind};
use proptest::prelude::*;
use proptest::sample::subsequence;
use crate::assert_panics;
use crate::common::csr_strategy;
use std::collections::HashSet;
#[test]
fn csr_matrix_valid_da... | the_stack |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.