text
stringlengths
2.5k
6.39M
kind
stringclasses
3 values
use super::parser; use super::semantics; use super::{LispErr, Pos}; use alloc::boxed::Box; use alloc::{ collections::{btree_map::BTreeMap, linked_list::LinkedList, vec_deque::VecDeque}, format, string::{String, ToString}, vec, vec::Vec, }; use core::{ cmp::{Eq, Ord, Ordering, PartialEq, Partial...
the_stack
use qt_widgets::QCheckBox; use qt_widgets::QDoubleSpinBox; use qt_widgets::QLabel; use qt_widgets::QLineEdit; use qt_widgets::QGridLayout; use qt_widgets::QSpinBox; use qt_widgets::QTreeView; use qt_widgets::QWidget; use qt_gui::QStandardItem; use qt_gui::QStandardItemModel; use qt_core::QBox; use qt_core::QPtr; use ...
the_stack
use rt::*; use gc::*; use syntax::Name; use syntax::ast::FunctionRef; use syntax::token::name; use std::f64; use std::cmp; trait SignedZero { #[inline(always)] fn is_positive_zero(&self) -> bool; #[inline(always)] fn is_negative_zero(&self) -> bool; } impl SignedZero for f64 { #[inline(always...
the_stack
/// The HPACK Huffman decoder. /// /// Give it a byte iterator and it’ll yield the bytes. pub struct HuffmanDecoder<I: Iterator<Item = u8>> { iter: Bits<I>, } impl<I: Iterator<Item = u8>> HuffmanDecoder<I> { /// Constructs a new `HuffmanDecoder` from the given byte iterator. pub fn new(iter: I) -> HuffmanD...
the_stack
use std::{ cmp::PartialOrd, fmt::Display, ops::{Add, AddAssign, Mul, Sub, SubAssign}, }; use num::{FromPrimitive, ToPrimitive}; use crate::{ sync::transfer::LVarSyncer, util::{float_eq, wrap_diff, NumberDigits}, }; const GROUP_ID: u32 = 5; pub trait Syncable<T> where T: Default, { fn set...
the_stack
use crate::core::server_messages::OutboundMessage; use futures::channel::mpsc::{UnboundedReceiver, UnboundedSender}; use std::{collections::VecDeque, sync::Arc}; #[macro_use] mod events; mod io; pub mod key; mod mailbox; mod running; mod server_messages; #[cfg(test)] mod test; mod util; mod wordlist; use self::events...
the_stack
use super::TrackAndTraceStoreOperations; use crate::track_and_trace::store::diesel::{schema::reporter, TrackAndTraceStoreError}; use crate::commits::MAX_COMMIT_NUM; use crate::error::{ConstraintViolationError, ConstraintViolationType, InternalError}; use crate::track_and_trace::store::diesel::models::{NewReporterModel...
the_stack
pub(crate) struct ParsedDisplay { pub(crate) host: String, pub(crate) protocol: Option<String>, pub(crate) display: u16, pub(crate) screen: u16, } pub(crate) fn parse_display(dpy_name: Option<&str>) -> Option<ParsedDisplay> { // If no dpy name was provided, use the env var. If no env var exists, re...
the_stack
use crate::{ builtins::{array_buffer::SharedMemoryOrder, typed_array::integer_indexed_object::ContentType}, object::JsObject, property::{PropertyDescriptor, PropertyKey}, Context, JsResult, JsValue, }; use super::{InternalObjectMethods, ORDINARY_INTERNAL_METHODS}; /// Definitions of the internal objec...
the_stack
use std::ops::{Deref, DerefMut}; use interner::InternedStr; use base::ast::{Literal, Pattern, TypedIdent}; use base::instantiate; use base::symbol::{Symbol, SymbolRef, SymbolModule}; use base::ast::{Typed, DisplayEnv, SpannedExpr, Expr}; use base::types; use base::types::{Alias, KindEnv, ArcType, Type, TypeEnv}; use ba...
the_stack
use crate::config::Config; use crate::executor::Executor; use crate::id::{ClientId, ProcessId, ShardId}; use crate::protocol::Protocol; use crate::run::prelude::*; use crate::run::task; use crate::time::RunTime; use crate::HashMap; use crate::{debug, trace, warn}; use std::sync::Arc; use tokio::time; /// Starts execut...
the_stack
use orbclient::{ self, Color, Event, EventOption, KeyEvent, MouseEvent, MouseRelativeEvent, ButtonEvent, ClipboardEvent, FocusEvent, HoverEvent, QuitEvent, MoveEvent, ResizeEvent, Renderer, ScreenEvent, TextInputEvent, }; use orbfont; use syscall; use orbital_core::{ Handler, Orbital, Propertie...
the_stack
use crate::err::{DeserializationError, DeserializationResult as Result, WrappedIoError}; pub use byteorder::{LittleEndian, ReadBytesExt}; use winstructs::guid::Guid; use crate::model::deserialized::*; use std::io::Cursor; use crate::binxml::deserializer::BinXmlDeserializer; use crate::binxml::name::BinXmlNameRef; us...
the_stack
use std::{ collections::HashMap, fmt::{self, Display, Formatter}, sync::{Arc, Mutex}, }; use crate::utils::errors::{AeronError, IllegalArgumentError, IllegalStateError}; pub const SPY_QUALIFIER: &str = "aeron-spy"; pub const AERON_SCHEME: &str = "aeron"; pub const AERON_PREFIX: &str = "aeron:"; pub const...
the_stack
#![no_std] #![no_main] #![feature(const_evaluatable_checked, const_generics)] #![allow(non_snake_case, incomplete_features)] use scale_std::array::*; use scale_std::fixed_point::*; use scale_std::ieee::*; use scale_std::integer::*; use scale_std::math::*; fn test_approx<const V: u64, const P: u64>(a: ClearFloat<V, P>...
the_stack
use std::marker; use std::ptr; use rayon::iter::plumbing::*; use rayon::prelude::*; use crate::std_hash::table::{RawBucket, RawTable}; struct SplitBuckets<'a, K, V> { bucket: RawBucket<K, V>, end: usize, marker: marker::PhantomData<&'a ()>, } impl<'a, K, V> SplitBuckets<'a, K, V> { fn new(table: &'a...
the_stack
extern crate gl; extern crate glfw; extern crate image; extern crate cgmath; extern crate rand; mod util; mod ico; mod rat; mod shader; mod maze; mod wall; mod walker; mod camera; mod texture; use std::env; use std::cmp; use std::ffi::CStr; use std::collections::HashMap; use cgmath::{Matrix3, Matrix4, Deg, perspecti...
the_stack
use fltk::{ app::{App, Scheme}, button::Button, enums::{Color, Event, Font}, group::*, menu::Choice, misc::Spinner, prelude::*, text::{StyleTableEntry, TextBuffer, TextEditor}, window::Window, }; use std::{cell::RefCell, char, rc::Rc}; struct Style { style_table: Vec<StyleTableE...
the_stack
use std::env::consts::ARCH; use std::ffi::CStr; use std::mem::MaybeUninit; use std::os::unix::process::parent_id; use std::sync::Arc; use std::time::{Duration, Instant}; use std::{fmt, io, process}; use log::{debug, error, info, trace}; use mio::event::Event; use mio::{Events, Interest, Poll, Registry, Token}; use mio...
the_stack
use crate::indexing::SpIndex; use crate::sparse::permutation::PermOwnedI; use crate::sparse::symmetric::is_symmetric; use crate::sparse::CsMatViewI; use std::collections::vec_deque::VecDeque; pub struct Ordering<I> { /// The computed permutation pub perm: PermOwnedI<I>, /// Indices inside the permutation d...
the_stack
use crate::{Buffer, BufferInfo, Context, Resource}; use ash::{version::DeviceV1_0, vk}; use std::sync::Arc; pub struct GeometryInstance { pub vertex_buffer: vk::Buffer, pub vertex_count: u32, pub vertex_offset: vk::DeviceSize, pub index_buffer: Option<vk::Buffer>, pub index_count: Option<u32>, ...
the_stack
use lazy_static::lazy_static; use log::{debug, error, warn}; use std::collections::HashMap; use std::ffi::{CStr, CString}; use std::marker::PhantomData; use std::os::raw::{c_char, c_int}; use std::sync::{mpsc, Arc, Mutex}; use std::{ptr, slice}; use wkhtmltox_sys::image::*; use super::{Error, ImageOutput, Result}; en...
the_stack
use crate::error::{GDBError, GDBResult}; use dyn_type::{BorrowObject, Object}; use pegasus_common::codec::{Decode, Encode}; use pegasus_common::io::{ReadExt, WriteExt}; use serde::de::Error as DeError; use serde::ser::Error as SerError; use serde::{Deserialize, Deserializer, Serialize, Serializer}; use std::collections...
the_stack
use crate::*; use std::fmt::Debug; use std::hash::Hash; /// The way the inventory size is handled. #[derive(new, Clone, Serialize, Deserialize, Debug)] pub enum InventorySizingMode { /// The inventory uses a fixed size. Fixed { /// The size of the inventory. size: usize, }, /// The inve...
the_stack
use rendy::{ command::{QueueId, RenderPassEncoder}, factory::Factory, graph::{render::*, GraphContext, ImageAccess, NodeBuffer, NodeImage}, hal::{device::Device, pso::DescriptorPool}, resource::{ Buffer, BufferInfo, DescriptorSetLayout, Escape, Filter, Handle, ImageView, ImageViewInfo, ...
the_stack
// This module contains the definition of `Protocol`, `ClientPlacement` and // `ProtocolStats`. pub mod protocol; // This module contains the definition of `Search`. pub mod search; // Re-exports. pub use search::{FTMetric, RankingParams, Search, SearchInput}; use fantoch::metrics::{Histogram, Stats}; use fantoch::p...
the_stack
use std::iter::FromIterator; use std::collections::HashSet; use std::convert::AsRef; use std::path::{PathBuf, Path}; use std::string::ToString; use tar::Archive; use flate2::read::GzDecoder; /////////////////////////////////////////////////////////////////////////////// // UTILS - ENVIROMENT /////////////////////////...
the_stack
use std::cmp::Ordering; use std::collections::HashSet; use std::sync::Arc; use kailua_env::{Pos, Span, Source}; use kailua_syntax::lex::{Tok, Punct, Keyword, NestedToken, NestingCategory}; use kailua_syntax::ast::Chunk; use kailua_types::ty::Key; use kailua_check::env::Output; use protocol::*; use super::{get_prefix_...
the_stack
use std::sync; use crate::ops::filter::{FilterCondition, Value}; use crate::ops::grouped::GroupedOperation; use crate::ops::grouped::GroupedOperator; pub use nom_sql::{Literal, Operator}; use crate::prelude::*; /// Supported aggregation operators. #[derive(Debug, Clone, PartialEq, Serialize, Deserialize)] pub enum F...
the_stack
since = "0.13.0", note = "The `sercom::v1::spi` module is deprecated, and will be removed in a subsequent release. Please use the `sercom::v2::spi` module instead." )] use core::marker::PhantomData; use crate::clock; use crate::hal::spi::{FullDuplex, Mode, Phase, Polarity}; use crate::pac::sercom0::SPI; use c...
the_stack
use crate::value::{NullScubaValue, ScubaValue}; use serde_json::{Error, Map, Number, Value}; use std::collections::hash_map::{Entry, HashMap}; use std::convert::Into; use std::time::{SystemTime, UNIX_EPOCH}; const TIME_COLUMN: &str = "time"; const INT_KEY: &str = "int"; const DOUBLE_KEY: &str = "double"; const NORMAL...
the_stack
use clippy_utils::consts::{constant_simple, Constant}; use clippy_utils::diagnostics::{span_lint, span_lint_and_help, span_lint_and_sugg, span_lint_and_then}; use clippy_utils::source::snippet; use clippy_utils::ty::match_type; use clippy_utils::{ higher, is_else_clause, is_expn_of, is_expr_path_def_path, is_lint_a...
the_stack
use core::convert::TryInto; use crate::error::Error; use crate::error::Result; use crate::jwk::EcCurve; use crate::jwk::EcxCurve; use crate::jwk::EdCurve; use crate::jwk::Jwk; use crate::jwk::JwkParamsEc; use crate::jwk::JwkParamsOct; use crate::jwk::JwkParamsOkp; use crate::jwk::JwkParamsRsa; use crate::lib::*; use c...
the_stack
#![warn(missing_docs, missing_debug_implementations, rust_2018_idioms)] use std::error; use std::fmt; use std::panic::{RefUnwindSafe, UnwindSafe}; use std::sync::atomic::{self, AtomicUsize, Ordering}; use crate::bounded::Bounded; use crate::single::Single; use crate::unbounded::Unbounded; mod bounded; mod single; mo...
the_stack
use crate::Container; use crate::Extractable; use crate::MetaContainer; use crate::TimelineElement; use glib::object::Cast; use glib::object::IsA; use glib::signal::connect_raw; use glib::signal::SignalHandlerId; use glib::translate::*; use glib::StaticType; use glib::ToValue; use std::boxed::Box as Box_; use std::mem:...
the_stack
#[allow(unused)] // TODO remove use core::fmt; use crate::{ gpio::{ gpioa::{PA1, PA2, PA3, PA6, PA7}, gpiob::{PB0, PB1, PB10, PB12, PB13, PB2, PB6}, gpioc::{PC1, PC10, PC11, PC2, PC3, PC5, PC9}, gpiod::{PD11, PD12, PD13, PD4, PD5, PD6, PD7}, gpioe::{PE10, PE11, PE2, PE7, PE8...
the_stack
#![allow(clippy::single_match)] use tracing; use wayland_protocols::xdg_shell::client::xdg_popup; use wayland_protocols::xdg_shell::client::xdg_positioner; use wayland_protocols::xdg_shell::client::xdg_surface; use super::application::{self, Timer}; use super::{error::Error, menu::Menu, outputs, surfaces}; use crate...
the_stack
use std::borrow::Cow; use std::collections::BTreeMap; use std::error::Error; use std::fs; use std::io::Write; use std::path::{Path, PathBuf}; use std::str; use std::sync::{Arc, Mutex}; use std::thread; use lazy_static::lazy_static; use crate::env::{ force_pass, force_update_snapshots, get_cargo_workspace, get_out...
the_stack
use crate::{BinaryError, ElectronApp, PatcherError}; use std::ops::Range; #[cfg(test)] use enum_iterator::IntoEnumIterator; /// A representation of a [fuse] that Electron has /// built in. They are used to disable specific functionality in the application in a way that can be enforced /// via signature checks and cod...
the_stack
use crate::pci::BarType; use cpuio::Port; use packets::ethernet::{ Address as MacAddress, Frame as EthernetFrame, Protocol as EthernetProtocol, Repr as EthernetRepr, }; use packets::ip::Protocol as IpProtocol; use packets::ipv4::{Address as Ipv4Address, Packet as Ipv4Packet, Repr as Ipv4Repr}; use packets::phy...
the_stack
use super::export; use super::import_export_dtos::*; use crate::sql_util::insert_row; use diesel::dsl::count; use diesel::prelude::*; use projectpadsql::models::EnvironmentType; use projectpadsql::sqlite_is; use std::collections::HashSet; use std::path::{Path, PathBuf}; use std::{borrow, fs, process, str}; type Import...
the_stack
use std::sync::Arc; use common_exception::ErrorCode; use common_exception::Result; use common_meta_types::CreateDatabaseReply; use common_meta_types::CreateDatabaseReq; use common_meta_types::CreateTableReq; use common_meta_types::DropDatabaseReq; use common_meta_types::DropTableReply; use common_meta_types::DropTable...
the_stack
fn test_paper_results() { use crate::pairing::bls12_381::{Bls12, Fr}; use std::time::{Instant}; let srs_x = Fr::from_str("23923").unwrap(); let srs_alpha = Fr::from_str("23728792").unwrap(); println!("making srs"); let start = Instant::now(); let srs = SRS::<Bls12>::dummy(830564, srs_x, srs...
the_stack
//! A lazy storage mapping that stores entries under their SCALE encoded key hashes. use super::{ CacheCell, EntryState, StorageEntry, }; use crate::traits::{ clear_packed_root, pull_packed_root_opt, ExtKeyPtr, KeyPtr, PackedLayout, SpreadAllocate, SpreadLayout, }; use core::{ ...
the_stack
use crate::errors::{Result, Error}; use crate::options::OptionMap; use crate::options::traits::{FromSudoOption, FromSudoOptionList}; use std::convert::TryFrom; use std::net::{AddrParseError, IpAddr}; use std::str; /// A vector of user-supplied sudo settings. These settings correspond /// to options the user specified...
the_stack
use crate::workflows::manager::WorkflowManagerRequest; use crate::workflows::WorkflowRequest; use futures::future::BoxFuture; use futures::stream::FuturesUnordered; use futures::{FutureExt, StreamExt}; use std::collections::{HashMap, HashSet}; use std::num::Wrapping; use tokio::sync::mpsc::{unbounded_channel, Unbounded...
the_stack
#![stable(feature = "unix_socket_redox", since = "1.29")] //! Unix-specific networking functionality use fmt; use io::{self, Error, ErrorKind, Initializer}; use net::Shutdown; use os::unix::io::{RawFd, AsRawFd, FromRawFd, IntoRawFd}; use path::Path; use time::Duration; use sys::{cvt, fd::FileDesc, syscall}; /// An a...
the_stack
use crate::battle::{Battle, BattleRules}; use crate::character::{Character, CharacterRules, Statistic, StatisticId, StatisticsSeed}; use crate::entity::{Entity, EntityId, Transmutation}; use crate::error::{WeaselError, WeaselResult}; use crate::event::{Event, EventKind, EventProcessor, EventQueue, EventTrigger}; use cr...
the_stack
use crate::{dom::*, value::Value}; use verify::{ span::{Span, Spanned}, Error, Validate, ValidateMap, ValidateSeq, }; use rowan::TextRange; use std::{convert::TryFrom, ops::AddAssign}; #[derive(Debug, Clone, Copy)] #[repr(transparent)] pub struct NodeSpan(pub TextRange); impl Span for NodeSpan {} impl From...
the_stack
use alloc::boxed::Box; use crate::{Face, GlyphInfo, Mask}; use crate::buffer::{Buffer, BufferFlags, BufferClusterLevel}; use crate::ot::{feature, FeatureFlags, Map}; use crate::plan::{ShapePlan, ShapePlanner}; use super::*; pub const HANGUL_SHAPER: ComplexShaper = ComplexShaper { collect_features: Some(collect_f...
the_stack
use std::{ cell::RefCell, ops::Deref, ptr, sync::atomic::{AtomicUsize, Ordering}, thread::current, }; use log::{debug, error}; use crate::{errors::*, sys, JNIEnv}; #[cfg(feature = "invocation")] use crate::InitArgs; /// The Java VM, providing [Invocation API][invocation-api] support. /// /// The...
the_stack
use proc_macro2::TokenStream; use quote::ToTokens; use syn::fold::Fold; mod arg_ast; mod mutate_args; pub mod transform_context; pub mod transform_info; pub use transform_context::TransformContext; use crate::mutator::*; use transform_info::SharedTransformInfo; pub fn do_transform_item(args: TokenStream, input: Toke...
the_stack
use sauron_core::{ diff, html::{attributes::*, events::*, *}, mt_dom::patch::*, Attribute, Node, *, }; #[test] fn nodes_with_event_must_be_replaced() { let elem_id = "input-remove-event-test"; let old: Node<()> = input( vec![ // On input we'll set our Rc<RefCell<String>> va...
the_stack
#![deny(missing_docs)] #![deny(meta_variable_misuse)] #![no_std] #[cfg(feature = "serde")] extern crate serde; #[cfg(test)] extern crate bincode; pub extern crate typenum; mod hex; mod impls; #[cfg(feature = "serde")] mod impl_serde; use core::iter::FromIterator; use core::marker::PhantomData; use core::mem::{May...
the_stack
extern crate ntp_parser; use self::ntp_parser::*; use core; use core::{AppProto,Flow,ALPROTO_UNKNOWN,ALPROTO_FAILED}; use applayer; use parser::*; use libc; use std; use std::ffi::{CStr,CString}; use log::*; use nom::IResult; #[repr(u32)] pub enum NTPEvent { UnsolicitedResponse = 0, MalformedData, NotReq...
the_stack
use byteorder::{ByteOrder, NetworkEndian}; use crate::wire::icmpv6::{field, Message, Packet}; use crate::wire::Ipv6Address; use crate::{Error, Result}; enum_with_unknown! { /// MLDv2 Multicast Listener Report Record Type. See [RFC 3810 § 5.2.12] for /// more details. /// /// [RFC 3810 § 5.2.12]: https...
the_stack
use super::sad::*; use super::tq::*; use super::util::*; use super::*; use crate::api::frame::*; use crate::api::*; use crate::def::*; use crate::ipred::*; use crate::itdq::*; use crate::picman::*; use crate::plane::*; use crate::recon::*; use crate::region::*; use std::cell::RefCell; use std::rc::Rc; /**************...
the_stack
clippy::cognitive_complexity, clippy::float_cmp, clippy::let_unit_value, clippy::module_inception, clippy::new_without_default, clippy::too_many_arguments, clippy::unreadable_literal )] #[macro_use] pub mod interpreter; pub mod ast; mod binary; pub mod func; pub mod ops; pub mod runtime; pub mo...
the_stack
use crate::Asset; use crate::Clip; use crate::Extractable; use crate::MetaContainer; use crate::Timeline; #[cfg(any(feature = "v1_18", feature = "dox"))] #[cfg_attr(feature = "dox", doc(cfg(feature = "v1_18")))] use crate::Track; use crate::TrackType; use glib::object::Cast; use glib::object::IsA; use glib::signal::con...
the_stack
use crate::block_number::BlockTag; #[cfg(test)] use crate::block_number::Tag; use crate::log::Log; use cita_types::traits::BloomTools; use cita_types::{Address, Bloom, H256}; use jsonrpc_types::rpc_types::{Filter as RpcFilter, FilterAddress, Topic, VariadicValue}; /// Address Filter. #[derive(Debug, PartialEq, Clone)]...
the_stack
#[non_exhaustive] #[derive(std::fmt::Debug)] pub struct BatchGetRecordError { /// Kind of error that occurred. pub kind: BatchGetRecordErrorKind, /// Additional metadata about the error, including error code, message, and request ID. pub(crate) meta: aws_smithy_types::Error, } /// Types of errors that c...
the_stack
//! Multi-signature implementation: A multi-signature is a protocol that allows //! a group of signers, each possessing a distinct private/public keypair, to //! produce a joint signature on a common message. The simplest multi-signature //! of a message is just a set of signatures containing one signature over the //!...
the_stack
use rand::Rng; use std::io::stdout; use std::thread; use std::time::Duration; use crossterm::{ cursor::{self}, event::{KeyCode, KeyEvent}, terminal::{self, disable_raw_mode, enable_raw_mode}, ExecutableCommand, Result, }; use crate::events::{send_events, KeyEventQueue}; use crate::screen_buffer::{Coor...
the_stack
extern crate dirs; extern crate gumdrop; extern crate ketos; extern crate linefeed; use std::cell::RefCell; use std::env::{split_paths, var_os}; use std::io::{self, stderr, Write}; use std::iter::repeat; use std::path::{Path, PathBuf}; use std::str::FromStr; use std::sync::Arc; use std::time::Duration; use gumdrop::{...
the_stack
use super::super::{frame_object::*, machine::register::*}; use super::inst::*; use crate::codegen::common::machine::{builder::*, function::*, module::MachineModule}; use crate::{ir::types::*, traits::pass::ModulePassTrait}; pub struct PrologueEpilogueInserter {} impl ModulePassTrait for PrologueEpilogueInserter { ...
the_stack
extern crate rand; use std::env; use std::f64; use std::io::{Error, ErrorKind}; use std::path; use std::str; use std::time::Instant; use std::sync::mpsc; use std::sync::Arc; use std::thread; use num_cpus; use rand::Rng; use whitebox_common::structures::{Array2D}; use whitebox_common::utils::get_formatted_elapsed_time;...
the_stack
use crate::raw_symbol_token::{local_sid_token, text_token}; use crate::text::parsers::containers::s_expression_end; use crate::text::parsers::stop_character; use crate::text::parsers::text_support::{escaped_char, escaped_newline, StringFragment}; use crate::text::text_value::TextValue; use nom::branch::alt; use nom::by...
the_stack
use chrono::offset::FixedOffset; use chrono::DateTime; use std::collections::HashMap; use crate::measurement::MeasurementVisitor; #[derive(Debug)] pub struct MeasurementGroup { timestamp: Option<DateTime<FixedOffset>>, values: HashMap<String, Measurement>, } impl MeasurementGroup { fn new() -> Self { ...
the_stack
use glsp::{bail, ensure, GResult, Num, Rest, Val}; use smallvec::SmallVec; use std::cmp::Ordering; use std::f32; pub fn init(_sandboxed: bool) -> GResult<()> { glsp::bind_rfn("+", &add)?; glsp::bind_rfn("-", &sub)?; glsp::bind_rfn("*", &mul)?; glsp::bind_rfn("/", &div)?; glsp::bind_rfn("%", &rem)?;...
the_stack
use core::{ptr, slice}; use std::{ffi::c_void, mem::MaybeUninit}; use com::{ interfaces::iunknown::IUnknown, sys::{FAILED, GUID, HRESULT, S_FALSE, S_OK}, }; use widestring::U16CString; use crate::{ cil::uncompress_token, ffi::{types::*, *}, profiler::types::{FunctionInfo, FunctionMethodSignature, ...
the_stack
use dns_parser::{Packet, RData}; use futures::{ channel::{mpsc, oneshot}, select, FutureExt, StreamExt, }; use futures_timer::Delay; use lazy_static::lazy_static; use nohash_hasher::IntMap; use smallvec::SmallVec; use std::{ convert::TryFrom, io, iter, net::{Ipv4Addr, SocketAddr}, str, time:...
the_stack
extern crate objc; extern crate objc_foundation; extern crate objc_id; use super::interface::*; use std::fmt; use std::rc::Rc; use std::cell::Cell; use std::sync::Once; use std::collections::BTreeMap; use objc::Message; use objc::declare::ClassDecl; use objc::runtime::{Class, Object, Sel}; use self::objc_foundation:...
the_stack
use std::collections::{BTreeMap, BTreeSet}; use std::task::Waker; use std::time::{Duration, Instant}; use std::{ collections::{HashMap, HashSet, VecDeque}, error, sync::Arc, task::{Context, Poll}, }; use ip_network::IpNetwork; use libp2p::swarm::DialPeerCondition; use libp2p::{ core::connection::Co...
the_stack
use std::borrow::Cow; use std::collections::BTreeMap; use std::convert::Infallible; use std::fmt; use std::ops::Deref; use std::str::FromStr; use chrono::{DateTime, Utc}; use serde::{de, Deserialize, Deserializer, Serialize}; use symbolic::common::{split_path, Arch, CodeId, DebugId, Language}; use symbolic::debuginfo:...
the_stack
use super::{MapBuilder, Map, TileType, Position, spawner, SHOW_MAPGEN_VISUALIZER, remove_unreachable_areas_returning_most_distant, generate_voronoi_spawn_regions}; use rltk::RandomNumberGenerator; use specs::prelude::*; use std::collections::HashMap; #[derive(PartialEq, Copy, Clone)] pub enum DLAAlgorithm { Wa...
the_stack
#![allow(missing_copy_implementations)] use audiodecoder; use platform::macos::coreaudio::{kAudioFormatFlagIsFloat, kAudioFormatFlagIsPacked}; use platform::macos::coreaudio::{kLinearPCMFormatFlagIsNonInterleaved, AudioBuffer}; use platform::macos::coreaudio::{AudioBufferList, AudioBufferListRef, AudioStreamBasicDescr...
the_stack
use clap::value_t_or_exit; use clap::{App, Arg}; use futures_util::future::TryFutureExt; use futures_util::future::{self, Either}; use lazy_static::lazy_static; use tower_service::Service; use trawler::{LobstersRequest, TrawlerRequest, Vote}; use std::collections::HashMap; use std::future::Future; use std::pin::Pin; u...
the_stack
use crate::eval_ptr::EvalPtr; use crate::interp::Interp; use crate::list; use crate::parser::Word; use crate::tokenizer::Tokenizer; use crate::*; //------------------------------------------------------------------------------------------------ // Datum Representation type DatumResult = Result<Datum, Exception>; ///...
the_stack
use core::mem; use std; use std::sync:: { Arc, Mutex, Condvar, }; use alloc::{SliceWrapper, Allocator}; use enc::BrotliAlloc; use enc::BrotliEncoderParams; use enc::backward_references::UnionHasher; use enc::threading::{ CompressMulti, SendAlloc, InternalSendAlloc, BatchSpawnableLite, Joinable, Owned...
the_stack
#![allow(unsafe_code)] #![allow(clippy::undocumented_unsafe_blocks)] use super::super::c; #[cfg(target_pointer_width = "64")] use super::super::conv::loff_t_from_u64; use super::super::conv::{ by_ref, c_int, c_uint, pass_usize, raw_fd, ret, ret_discarded_fd, ret_owned_fd, ret_usize, slice, slice_mut, zero, }; ...
the_stack
mod config; mod error; mod rttui; use anyhow::{anyhow, Context, Result}; use chrono::Local; use colored::*; use std::{ env, fs, fs::File, io::Write, panic, path::Path, process, sync::{Arc, Mutex}, time::{Duration, Instant}, }; use structopt::StructOpt; use probe_rs::{ config::Targe...
the_stack
//**************************************************************************** // Automatically generated from yaml/swiftnav/sbp/system.yaml // with generate.py. Please do not hand edit! //****************************************************************************/ //! Standardized system messages from Swift Navigatio...
the_stack
use std::fmt; use std::time::Duration; use glium::glutin::{ElementState, VirtualKeyCode, WindowEvent}; use imgui::{im_str, ImString}; use log::info; use nalgebra as na; use crate::util::timer::{self, Timer}; /// Possible choices in the UI for number of ticks per second to play. /// (Specifying these as strings inste...
the_stack
use chrono::{DateTime, Local}; use std::cmp::min; use std::collections::HashSet; use std::num::NonZeroUsize; use std::time::{Instant, SystemTime}; use cpu_time::ProcessTime; use hdrhistogram::Histogram; use serde::{Deserialize, Serialize}; use statrs::distribution::{StudentsT, Univariate}; use strum::EnumCount; use st...
the_stack
use crate::runtime::reify::Reifiable; use std::{clone::Clone, fmt, hash::Hash, rc::Rc}; extern crate im_rc; use self::im_rc::HashMap; thread_local! { static next_id: std::cell::RefCell<u32> = std::cell::RefCell::new(0); } fn get_next_id() -> u32 { next_id.with(|id| { let res = *id.borrow(); ...
the_stack
use crate::ast::*; use crate::util::{nspaces, PP}; use std::fmt; use std::io; impl<Ty: PP, DE: PP, DS: PP> PP for Context<Ty, DE, DS> { fn pp<W: io::Write>(&self, w: &mut W, indent: usize) -> io::Result<()> { self.1.pp(w, indent) } } impl<Ty: fmt::Display, DE: fmt::Display, DS: fmt::Display> fmt::Disp...
the_stack
use sgx_rand::*; // pub use os::SgxRng pub fn test_rand_os_sgxrng() { let mut os_rng = os::SgxRng::new().unwrap(); let mut checksum_u32: u32 = 0; let mut checksum_u64: u64 = 0; let testcount = 1000; for _ in 0..testcount { checksum_u32 |= os_rng.next_u32(); checksum_u64 |= os_rng.ne...
the_stack
use criterion::Criterion; use crate::{define, memmem::inputs::INPUTS}; mod imp; mod inputs; mod sliceslice; pub fn all(c: &mut Criterion) { oneshot(c); prebuilt(c); oneshot_iter(c); prebuilt_iter(c); sliceslice::all(c); } fn oneshot(c: &mut Criterion) { macro_rules! def_impl { ($inp:...
the_stack
extern crate num_traits; use num_traits::{Float, Zero}; use crate::SampledTree; use crate::visitor::AnomalyScoreVisitor; use std::marker::PhantomData; use std::iter::Sum; /// A random cut forest model. /// /// Random cut forests are model-free data structures for sketching data /// streams. This type is the main int...
the_stack
use crate::recorder::Recorder; use rand_core::{RngCore, SeedableRng}; use rand_xorshift::XorShiftRng; use serde::{Deserialize, Serialize}; use std::time::SystemTime; pub const PI2F: f32 = 2.0 * std::f32::consts::PI; pub const PI4F: f32 = 4.0 * std::f32::consts::PI; pub const WAVEGUIDE_MAX_AMP: f32 = 20.0; // at this ...
the_stack
//! Reuse builds performed earlier. //! //! Nextest allows users to reuse builds done on one machine. This module contains support for that. //! //! The main data structures here are [`ReuseBuildInfo`] and [`PathMapper`]. use crate::{ errors::{ ArchiveExtractError, ArchiveReadError, PathMapperConstructErro...
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
use crate::error::ContractError; use crate::transactions::OLD_DELEGATIONS_CHUNK_SIZE; use cosmwasm_std::{Decimal, Order, StdError, StdResult, Uint128}; use cosmwasm_storage::ReadonlyBucket; use mixnet_contract::{Addr, IdentityKey, PagedAllDelegationsResponse, UnpackedDelegation}; use serde::de::DeserializeOwned; use se...
the_stack
use std::hash::Hash; use std::{mem, ptr}; use std::sync::atomic; use sponge::Sponge; use conc; /// A key-value pair. #[derive(Clone)] pub struct Pair<K, V> { // The key. pub key: K, // The value. pub val: V, } /// A node in the tree. enum Node<K, V> { /// A leaf containing a key-value pair. Le...
the_stack
use crate::cache::*; use crate::device::*; use crate::error::*; use crate::pool::*; use std::borrow::BorrowMut; use std::collections::hash_map::DefaultHasher; use std::hash::{Hash, Hasher}; use std::io::{Read, Seek}; use std::sync::Arc; // TODO in the future, generalize this to other types, not just struct /// A tra...
the_stack
use std::{ collections::{BTreeMap, HashMap, HashSet}, sync::Arc, time::{SystemTime, UNIX_EPOCH}, }; use anyhow::Result; use byteorder::{BigEndian, ByteOrder}; use rand::RngCore; use crate::schema::compile::{CompiledSchema, FieldAnnotation, FieldAnnotationList, FieldType}; use super::{StorageKey, StorageNode, S...
the_stack
use super::util::Log2FloorNonZero; use super::encode::BROTLI_NUM_DISTANCE_SHORT_CODES; #[derive(Copy,Clone, Debug)] pub struct BrotliDistanceParams { pub distance_postfix_bits : u32, pub num_direct_distance_codes : u32, pub alphabet_size : u32, pub max_distance : usize, } #[derive(Clone, Copy, Debug)] ...
the_stack
cfg_if::cfg_if!{ if #[cfg(feature="test")] { #[macro_use] #[path="imp-test.rs"] #[doc(hidden)] pub mod imp; } else { #[macro_use] //#[cfg_attr(arch="amd64", path="amd64/mod.rs")] #[cfg_attr(target_arch="x86_64", path="amd64/mod.rs")] #[cfg_attr(arch="armv7", path="armv7/mod.rs")] #[cfg_attr(target_...
the_stack
//! # Policy Compiler //! //! Optimizing compiler from concrete policies to Miniscript //! use std::collections::BTreeMap; use std::convert::From; use std::marker::PhantomData; use std::{cmp, error, f64, fmt, mem}; use miniscript::limits::MAX_PUBKEYS_PER_MULTISIG; use miniscript::types::{self, ErrorKind, ExtData, Pro...
the_stack
use self::assets::Asset; use crate::api; use crate::api::setbac::ConnectionMeta; use crate::auth; use crate::bus; use crate::currency::Currency; use crate::db; use crate::injector; use crate::message_log; use crate::player; use crate::prelude::*; use crate::template; use crate::track_id::TrackId; use crate::utils; use ...
the_stack