text
stringlengths
9.08k
47.9k
use pkcs11_sys as sys; use super::to_ck_long; //------------ Macros for Making Types --------------------------------------- /// Wrapper for creating all the types. macro_rules! ck_types { ( $( $(#[$attr:meta])* type $typename:ident { $( $(#[$i...
// Copyright (c) The Diem Core Contributors // SPDX-License-Identifier: Apache-2.0 //! Analysis which computes information needed in backends for monomorphization. This //! computes the distinct type instantiations in the model for structs and inlined functions. //! It also eliminates type quantification (`forall coin...
use std::{ fmt::Debug, fs::{File, OpenOptions}, io::{Read, Seek, SeekFrom}, os::unix::fs::MetadataExt, path::PathBuf, sync::atomic::{AtomicU64, Ordering}, time::SystemTime, }; use bytes::Buf; use encoding_rs::KOI8_R; use io::Reader; use thiserror::Error; use tracing::{debug, instrument, tra...
use std::{ env, fmt::{Display, Formatter}, }; use http::Request; use hyper::{header::LOCATION, Body, StatusCode}; use indexmap::IndexMap; use rand::{prelude::ThreadRng, Rng}; use serde::{Deserialize, Serialize}; use tokio::{ select, time::{sleep, Duration}, }; use url::{ParseError, Url}; use vector_cor...
/// A span represents a single operation within a trace. Spans can be /// nested to form a trace tree. Spans may also be linked to other spans /// from the same or different trace. And form graphs. Often, a trace /// contains a root span that describes the end-to-end latency, and one /// or more subspans for its sub-op...
// Copyright © 2020 <NAME>. // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal // in the Software without restriction, including without limitation the rights // to use, copy, modify, merge, publish, distrib...
use std::fmt::Formatter; use Argument::*; extern crate strum; #[macro_use] extern crate strum_macros; pub mod command; pub use command::*; pub mod argument; pub use argument::*; #[derive(IntoStaticStr)] pub enum Cmd { NOP, NOPU, LXI, STAX, INX, INR, DCR, MVI, RLC, DAD, LD...
// Copyright 2018 The Fuchsia Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. use { crate::amber_connector::AmberConnect, crate::repository_manager::RepositoryManager, crate::rewrite_manager::RewriteManager, failure::...
//! Bridges the main thread and the audio thread. mod active_ids; mod backend; pub mod error; #[cfg(test)] mod tests; use std::{ hash::Hash, io::{stderr, Write}, sync::Arc, }; use active_ids::ActiveIds; #[cfg(not(feature = "benchmarking"))] use backend::Backend; #[cfg(feature = "benchmarking")] pub use backend::B...
use std::collections::HashSet; use std::env; use std::error::Error; use std::fs; use std::fs::File; use std::io; use std::io::BufWriter; use std::io::ErrorKind; use std::io::Write; use std::path::Path; use std::result::Result; use tensorflow_op_codegen::parser; use tensorflow_op_codegen::protos::OpDef; use ::protobuf:...
use std::cmp::min; use std::convert::TryFrom; use std::pin::Pin; use std::task::{Context, Poll}; use lazy_static::lazy_static; use log::trace; use string_wrapper::StringWrapper; use tokio::io::AsyncWrite; use tokio::prelude::AsyncRead; use crate::fixed_buffer::FixedBuf; pub mod buffer; pub mod async_write_logger; pu...
//! # Algorithm //! //! For an atom and type on input (when type is not set `Undefined` is used): //! * [Atom::Variable] is returned as is. //! * [Atom::Symbol] and [Atom::Grounded] are type checked: //! * If type is corrent then atom is returned as is. //! * If type is incorrect then error result is returned. //! ...
#![allow(dead_code)] #![deny(non_snake_case)] //#![deny(unused_imports)] #![deny(unused_must_use)] extern crate remark_common as rcommon; extern crate remark_log as rlog; extern crate remark_proto as rproto; mod error; mod raft; mod rpc; use prost::{Message as PMessage}; use std::collections::HashMap; use std::io::p...
use bytes::{BufMut, BytesMut}; use half::f16; use nalgebra::*; use std::{convert::TryInto, fs, path::PathBuf}; use std::{fs::OpenOptions, io::Write}; use crate::{vertex::AnnoData, RdModell}; use byteorder::ByteOrder; pub struct RdWriter { meta_deref: u32, input: RdModell, buf: BytesMut, } impl RdWriter ...
//===================================================================// // Copyright (c) 2019, <NAME> // Copyright (c) 2018, <NAME> // Copyright (c) 2004, <NAME> // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions are // met: // -...
//! Implementation of `cargo-build-ci`. use std::collections::{HashMap, HashSet}; use std::path::Path; use std::process::Output; use std::sync::{mpsc, Arc, Mutex}; use anyhow::{bail, Context}; use cargo_metadata::{Metadata, MetadataCommand}; use cargo_util::{paths, ProcessBuilder, ProcessError}; use colored::Colorize...
use std::fmt; use rustc_codegen_ssa::traits::BackendTypes; use rustc_target::spec::{HasTargetSpec, Target}; use cranelift_module::Module; use crate::prelude::*; pub fn mir_var(loc: Local) -> Variable { Variable::with_u32(loc.index() as u32) } pub fn pointer_ty(tcx: TyCtxt) -> types::Type { match tcx.data_l...
// Copyright 2020 ChainSafe Systems // SPDX-License-Identifier: Apache-2.0, MIT // Contains the implementation of Message Pool component. // The Message Pool is the component of forest that handles pending messages for inclusion // in the chain. Messages are added either directly for locally published messages // or t...
use chrono::{Datelike, NaiveDate, NaiveDateTime, Timelike, Weekday}; use serde::{Deserialize, Deserializer}; use std::fmt::Formatter; use std::str::FromStr; #[derive(Copy, Clone, Debug, Eq, PartialEq)] pub(crate) enum SaveInterval { /// every **:\[012345]\[05]:00 UTC Every5Minute, /// every **:\[012345]0:0...
pub mod bitcoind_client; mod cli; mod convert; mod disk; mod hex_utils; use crate::bitcoind_client::BitcoindClient; use crate::disk::FilesystemLogger; use bitcoin::blockdata::constants::genesis_block; use bitcoin::blockdata::transaction::Transaction; use bitcoin::consensus::encode; use bitcoin::network::constants::Net...
use std::alloc::{alloc, dealloc, Layout}; use std::borrow::Cow; use std::convert::Infallible; #[cfg(feature = "tempfile")] use std::fs::File; use std::io::{Cursor, Read, Seek, SeekFrom, Write}; use std::mem::{align_of, size_of}; use std::{cmp, io, ops, slice}; use bytemuck::{cast_slice, cast_slice_mut, Pod, Zeroable};...
// Copyright 2018 Parity Technologies (UK) Ltd. // // Permission is hereby granted, free of charge, to any person obtaining a // copy of this software and associated documentation files (the "Software"), // to deal in the Software without restriction, including without limitation // the rights to use, copy, modify, mer...
use std::cell::RefCell; use std::rc::{Rc, Weak}; use std::sync::atomic::{AtomicBool, Ordering}; use crate::bucket::Bucket; use crate::consts::{Flags, MIN_KEYS_PER_PAGE, PGID}; use crate::errors::Error; use crate::page::{BranchPageElement, LeafPageElement, Page}; use crate::utils::clamp; use super::{INode, NodeBuilder...
use curv::{arithmetic::Converter, elliptic::curves::Secp256k1, BigInt}; use log::{error, info, trace, warn}; use sc_keystore::LocalKeystore; use sp_core::sr25519; use sp_runtime::traits::AtLeast32BitUnsigned; use std::{collections::HashMap, path::PathBuf, sync::Arc}; use super::{keygen::*, offline::*, sign::*}; use s...
//! Utilities for dealing with GSM 03.40 Protocol Data Units (PDUs). //! //! See [this Wikipedia article](https://en.wikipedia.org/wiki/GSM_03.40) for more genreal //! information on the format of PDUs. //! //! As of the time of writing, this library's implementation of PDUs can be classed as "passable" - //! in that i...
use crate::decode::lzbuffer::{LzBuffer, LzCircularBuffer}; use crate::decode::lzma::{DecoderState, LzmaParams}; use crate::decode::rangecoder::RangeDecoder; use crate::decompress::Options; use crate::error; use crate::io::{self, BufRead, Cursor, Read, Write}; use crate::option::GuaranteedOption as Option; use crate::op...
//! A `Mill` hands out parcels of span data and associated span //! metadata to `Press`es. We expect multiple `Press`es to share //! the same `Mill`, and `Press`es belong to `ClassInfo`, and are //! thus immortal; `Mill`s are also immortal. //! //! Each `Mill` owns a large `Chunk`, and associated range of //! metadata...
use alloc::string::String; use crate::{idl::{JS_AST, JS_Schema}, schema::NP_Value_Kind, utils::opt_err}; use crate::{error::NP_Error, json_flex::{JSMAP, NP_JSON}, memory::{NP_Memory}, pointer::{NP_Value}, pointer::{NP_Cursor}, schema::NP_Parsed_Schema, schema::{NP_Schema, NP_TypeKeys}}; use alloc::borrow::ToOwned; use...
use super::*; use std::fmt; use std::fmt::{Display, Formatter}; use std::collections::hash_map::DefaultHasher; use std::hash::{Hash, Hasher}; const HIST_SIZE: usize = 5; const KIFU_TABLE: [char; 20] = [ 'a','b','c','d','e','f','g','h','i','j','k','l','m','n','o','p','q','r','s','t' ]; pub enum Dir { Left, Right...
use std::collections::HashMap; use config; use error::Result; use joint::Joint; use light::LastStableBallAndParentUnitsAndWitnessListUnit; use mc_outputs; use object_hash; use paid_witnessing; use rusqlite::Connection; use serde_json::{self, Value}; use signature::Signer; use spec; use spec::*; #[derive(Debug)] struc...
mod uint; use std::collections::BTreeMap; use std::convert::{TryFrom, TryInto}; use execution_engine::engine::{Error as EngineError, ExecutionResult, RootNotFound}; use execution_engine::execution::Error as ExecutionError; use ipc; use shared::newtypes::Blake2bHash; use storage::{gs, history, history::CommitResult, o...
use std::{ collections::{hash_map::Entry, HashMap, HashSet}, sync::{atomic::Ordering, Arc}, time::Duration, }; use encoding_rs::Encoding; use mime::Mime; use mongodb::{ bson::{doc, Bson, Document}, options::{InsertManyOptions, InsertOneOptions, UpdateOptions}, Collection, }; use reqwest::{redir...
//! Interface for writing object files. #![allow(clippy::cognitive_complexity)] #![allow(clippy::collapsible_if)] #![allow(clippy::comparison_chain)] #![allow(clippy::single_match)] #![allow(clippy::useless_let_if_seq)] use std::collections::HashMap; use std::string::String; use std::vec::Vec; use std::{error, fmt, r...
// Copyright (c) The Diem Core Contributors // SPDX-License-Identifier: Apache-2.0 use crate::{ compilation::package_layout::CompiledPackageLayout, resolution::resolution_graph::{Renaming, ResolvedGraph, ResolvedPackage, ResolvedTable}, source_package::{ layout::{SourcePackageLayout, REFERENCE_TEMP...
#![feature(cfg_target_has_atomic)] // `#[cfg(target_has_atomic_load_store)]` #![feature(atomic_mut_ptr)] #![feature(thread_local)] #![feature(deadline_api)] #![cfg_attr( feature = "doc", doc(html_logo_url = "https://r3-os.github.io/r3/logo-small.svg") )] #![doc = include_str!("./lib.md")] #![deny(unsafe_op_in_u...
use crate::model::filename::DocumentType; use crate::model::repo::RepoSource; use crate::model::repo::RepoState; use crate::pure_functions::files; use crate::repo::schema::{OneKey, Tx}; use crate::service::{api_service, file_encryption_service, file_service}; use crate::{Config, CoreError}; use lockbook_crypto::clock_s...
// Copyright 2021 The Simlin Authors. All rights reserved. // Use of this source code is governed by the Apache License, // Version 2.0, that can be found in the LICENSE file. use std::borrow::BorrowMut; use std::collections::HashMap; use std::rc::Rc; use float_cmp::approx_eq; use smallvec::SmallVec; use crate::byte...
use bulletproofs::r1cs; use bulletproofs::r1cs::R1CSProof; use curve25519_dalek::ristretto::CompressedRistretto; use curve25519_dalek::scalar::Scalar; use merlin::Transcript; use musig::Signature; use serde::de::Visitor; use serde::{self, Deserialize, Deserializer, Serialize, Serializer}; use spacesuit; use spacesuit::...
#[doc = r"Register block"] #[repr(C)] pub struct RegisterBlock { #[doc = "0x00 - Start 2-Wire master receive sequence."] pub tasks_startrx: TASKS_STARTRX, _reserved1: [u8; 4usize], #[doc = "0x08 - Start 2-Wire master transmit sequence."] pub tasks_starttx: TASKS_STARTTX, _reserved2: [u8; 8usize]...
use protobuf::ProtobufEnum; use protobuf::RepeatedField; use serde::Serialize; use crate::onnx; use crate::onnx::OperatorSetIdProto; use crate::onnx::TensorProto_DataType; use crate::onnx::ValueInfoProto; use num::FromPrimitive; use std::borrow::Cow; use std::convert::From; use std::convert::Into; use std::convert::Tr...
use crate::{initialize, pluralize}; const BASIC_TESTS: &'static [[&str; 2]] = &[ // Uncountables. ["firmware", "firmware"], ["fish", "fish"], ["media", "media"], ["moose", "moose"], ["police", "police"], ["sheep", "sheep"], ["series", "series"], ["agenda", "agenda"], ["news", "n...
//! Types and functions related to graphical outputs //! //! This modules provides two main elements. The first is the //! [`OutputHandler`](struct.OutputHandler.html) type, which is a //! [`MultiGlobalHandler`](../environment/trait.MultiGlobalHandler.html) for //! use with the [`init_environment!`](../macro.init_envir...
//! Matrix of an arbitrary type and utilities to rotate, transpose, etc. use crate::directed::bfs::bfs_reach; use crate::utils::uint_sqrt; use itertools::iproduct; use itertools::Itertools; use num_traits::Signed; use std::collections::BTreeSet; use std::ops::{Deref, DerefMut, Index, IndexMut, Neg, Range}; use std::sl...
use crate::formatter_traits::FormatTokenAndNode; use crate::{ empty_element, format_elements, group_elements, hard_group_elements, hard_line_break, join_elements, soft_block_indent, soft_line_break_or_space, soft_line_indent_or_space, space_token, token, FormatElement, FormatResult, Formatter, ToFormatEleme...
use std::collections::HashMap; use std::marker::PhantomData; use log::{info, trace}; use merkletree::merkle::FromIndexedParallelIterator; use merkletree::store::{DiskStore, StoreConfig}; use paired::bls12_381::Fr; use rayon::prelude::*; use sha2::{digest::generic_array::GenericArray, Digest, Sha256}; use crate::drgra...
// Copyright Materialize, Inc. and contributors. All rights reserved. // // Use of this software is governed by the Business Source License // included in the LICENSE file. // // As of the Change Date specified in that file, in accordance with // the Business Source License, use of this software will be governed // by ...
//! The `Visitor` responsible for actually checking a `mir::Body` for invalid operations. use rustc::middle::lang_items; use rustc::mir::visit::{MutatingUseContext, NonMutatingUseContext, PlaceContext, Visitor}; use rustc::mir::*; use rustc::ty::cast::CastTy; use rustc::ty::{self, Instance, InstanceDef, TyCtxt}; use r...
// Copyright 2020-2021, The Tremor Team // // 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 // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agr...
// Copyright (c) The Diem Core Contributors // SPDX-License-Identifier: Apache-2.0 use anyhow::{bail, format_err, Result}; use bytecode_source_map::source_map::SourceMap; use move_binary_format::{ access::ModuleAccess, file_format::{ AbilitySet, AddressIdentifierIndex, CodeOffset, Constant, ConstantPoo...
// Copyright 2019-2021 Parity Technologies (UK) Ltd. // This file is part of Parity Bridges Common. // Parity Bridges Common is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation, either version 3 of the License, ...
// Copyright 2021 The Fuchsia Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. // The journal is implemented as an ever extending file which contains variable length records that // describe mutations to be applied to various objects....
use std::ffi::CString; use dpdk_rs::{ rte_mempool_calc_obj_size, rte_mempool_objsz, rte_strerror, rte_errno, rte_mbuf, rte_pktmbuf_pool_create, rte_pktmbuf_free, rte_pktmbuf_clone, rte_pktmbuf_trim, rte_pktmbuf_adj, rte_pktmbuf_alloc, rte_mempool, rte_mempool_objhdr, ...
use crate::col_usage::{ collect_delete_subqueries, collect_select_subqueries, collect_update_subqueries, node_external_trans_tables, ColUsageNode, }; use crate::common::{ lookup, lookup_pos, merge_table_views, mk_qid, CoreIOCtx, OrigP, QueryPlan, TMStatus, Timestamp, }; use crate::model::common::{ proc, CQueryP...
use std::{ fmt, io::{self, Read, Write}, num::Wrapping, marker::Sized, convert::From, }; #[allow(unused_imports)] use ::cpu::{Cpu, Reg, CpuFlags, CpuIndex, CpuIndexable}; use ::memory::{MemReg, MemSize}; // size type id // [bb][bbbbbb][bbbbbbbb] // // type is Binary, Unary, Manip, etc // ...
use crate::context::*; use crate::position::*; use crate::types::*; use crate::util::*; use indoc::formatdoc; #[cfg(test)] use indoc::indoc; use itertools::Itertools; use lsp_types::*; use ropey::{Rope, RopeSlice}; use std::fs::File; use std::io::{BufReader, BufWriter, Write}; use std::os::unix::io::FromRawFd; pub tra...
//! The module for all things relating to the IO Register portion of the GBA's //! memory map. //! //! Here we define many constants for the volatile pointers to the various IO //! registers. Each raw register constant is named according to the name given //! to it in GBATEK's [GBA I/O //! Map](http://problemkaputt.de/...
// Copyright 2018 The Fuchsia Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. //! The special-purpose event loop used by the recovery netstack. //! //! This event loop takes in events from all sources (currently ethernet devices, FID...
#[doc = r"Register block"] #[repr(C)] pub struct RegisterBlock { #[doc = "0x00 - Version ID Register"] pub verid: VERID, #[doc = "0x04 - Parameter Register"] pub param: PARAM, #[doc = "0x08 - FlexIO Control Register"] pub ctrl: CTRL, #[doc = "0x0c - Pin State Register"] pub pin: PIN, #[doc = "0x10 - S...
// Copyright (c) 2019 <NAME>, RWTH Aachen University // // Licensed under the Apache License, Version 2.0, <LICENSE-APACHE or // http://apache.org/licenses/LICENSE-2.0> or the MIT license <LICENSE-MIT or // http://opensource.org/licenses/MIT>, at your option. This file may not be // copied, modified, or distributed exc...
/// Project: Generation of word digrams (2 grams) pt_PT in Rust /// /// Author: <NAME> /// Date: 2022.01.15 /// /// Description: This small project is a efficient way of generating a digrams /// file and frequency of words file for pt_PT (Portuguese) from the /// European Parliament Procee...
// Copyright (c) 2020 DDN. All rights reserved. // Use of this source code is governed by a MIT-style // license that can be found in the LICENSE file. use crate::{ api_utils::{get, get_all, get_hosts, post, put, wait_for_cmds, wait_for_cmds_success}, display_utils::{ display_cancelled, display_error, ...
use std::borrow::Cow; use std::convert::{TryFrom, TryInto}; use std::error::Error; use std::fmt::{Display, Formatter}; use std::ops::Deref; /// The error type for errors related to the parsing of namespace strings. #[derive(Clone, Debug, Eq, Ord, PartialEq, PartialOrd, Hash)] #[allow(missing_docs)] pub enum NsErr { ...
/////////////////////////////////////////////////////////////////////////////// // // Copyright 2018-2021 Robonomics Network <<EMAIL>> // // 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 ...
const BLOCK_SIZE: usize = 64; const STATE_SIZE: usize = 4; const RESULT_SIZE: usize = 16; const INIT_STATE: [u32; STATE_SIZE] = [0x67452301, 0xefcdab89, 0x98badcfe, 0x10325476]; const S11: u32 = 7; const S12: u32 = 12; const S13: u32 = 17; const S14: u32 = 22; const S21: u32 = 5; const S22: u32 = 9; const S23: u32 = ...
//! This file defines data structures to store contents in bom file //! as well as all management on these strcutures. //! Structures `Bom`, `Target`, `SymLink`, `Source`, `NormalFile`, `FileWithOption` //! are used to parse the bom file. //! Structures ending with `management` are used to define managements on differe...
use crate::position::{CubePosition, LayerPosition}; use crate::indexed::{IndexedCube, Target}; use crate::mask::{Mask, BitCube}; use crate::view::{ColumnMut, QuadMut}; use std::slice; use std::ops::Index; pub struct Sector<T> { chunks: Box<[Option<T>]>, present: BitCube } impl<T> Sector<T> { pub fn new() -> Self {...
const INVALID_VALUE: u8 = 255; const SIZE: i64 = 64; pub(crate) fn encode(mut num: i64) -> String { let mut res = Vec::<char>::new(); loop { res.push(ENCODE_MAP[(num % SIZE) as usize]); num /= SIZE; if num <= 0 { break; } } res.into_iter().rev().collect() } pu...
use super::*; #[cfg(target_os = "macos")] use dispatch::Queue; use enigo::{Enigo, Key, KeyboardControllable, MouseButton, MouseControllable}; use hbb_common::{config::COMPRESS_LEVEL, protobuf::ProtobufEnumOrUnknown}; use std::{ convert::TryFrom, sync::atomic::{AtomicBool, Ordering}, time::Instant, }; #[der...
use std::cell::RefCell; use std::sync::Arc; use cita_trie::DB; use ethereum_types::{Address, H256, U256}; use evm::InterpreterParams; use hashbrown::{HashMap, HashSet}; use log::debug; use rlp::RlpStream; use crate::common; use crate::err; use crate::evm; use crate::native; use crate::state::{self, State, StateObject...
// Moving Lambolt Terms to/from runtime, and building dynamic functions. // TODO: "dups" still needs to be moved out on alloc_body etc. use crate::language as lang; use crate::readback as rd; use crate::rulebook as rb; use crate::runtime as rt; use std::iter; use std::time::Instant; use std::collections::{HashMap}; u...
use std::any::{Any, TypeId}; use std::collections::HashMap; use std::error::Error as StdError; use std::fmt::Write; use std::os::raw::{c_int, c_void}; use std::panic::{catch_unwind, resume_unwind, AssertUnwindSafe}; use std::sync::{Arc, Mutex}; use std::{mem, ptr, slice}; use once_cell::sync::Lazy; use crate::error::...
//! Compatibility between different async runtimes for Arti //! //! # Overview //! //! Rust's support for asynchronous programming is powerful, but still //! a bit immature: there are multiple powerful runtimes you can use, //! but they do not expose a consistent set of interfaces. //! //! The [`futures`] API abstracts...
#![allow(unused)] use std::{env, fmt::Debug, path::PathBuf, rc::Rc}; use crate::{ core::errors::CmderError, parse::{matches::ParserMatches, parser::Parser, Argument}, ui::formatter::FormatGenerator, utils::{self, HelpWriter}, Event, Pattern, PredefinedTheme, Theme, }; use super::events::EventListe...
#[doc = r"Register block"] #[repr(C)] pub struct RegisterBlock { #[doc = "0x00 - Status And Control"] pub sc: SC, #[doc = "0x04 - Counter"] pub cnt: CNT, #[doc = "0x08 - Modulo"] pub mod_: MOD, #[doc = "0x0c - Channel (n) Status And Control"] pub c0sc: CSC, #[doc = "0x10 - Channel (n...
// /proc/[pid]/stat // // Status information about the process. This is used by ps(1). // It is defined in the kernel source file fs/proc/array.c. // // The fields, in order, with their proper scanf(3) format speci‐ // fiers, are listed below. Whether or not certain of these // fields display valid information is gov...
/* 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 https://mozilla.org/MPL/2.0/. */ //! The [`@viewport`][at] at-rule and [`meta`][meta] element. //! //! [at]: https://drafts.csswg.org/css-device-a...
//! Obfuscate ID into Hashids, for public, polite, and less predictible identifiers. //! //! Hashid allows short, seemingly random, ids. They are unique by using a secret salt. //! //! Principle of this library: //! Use the [HashidBuilder](struct.HashidBuilder) to configure, then use the returned [codec](struct.Hashi...
use crate::{ client, cmd::{self, Command, List, OrderBy, Query, User}, icon::Icon, service::{ self, auth, CacheKey, Comment, CommentStyle, Lang, LangInfo, Problem, ServiceProvider, Session, }, template::{parse_code, InjectPosition, Pattern}, Config, Either, InjectCode, LeetUp...
/*! # `Adbyss`: Hosts */ use adbyss_psl::{ AHASH_STATE, Domain, }; use crate::{ AdbyssError, FLAG_BACKUP, FLAG_COMPACT, FLAG_Y, MAX_LINE, Source, }; use fyi_msg::confirm; use dactyl::NiceU64; use rayon::{ iter::{ IntoParallelRefIterator, ParallelDrainFull, ParallelExtend, ParallelIterator, }, prelud...
use crate::constants::CapabilityFlag::{ CapabilityClientConnAttr, CapabilityClientConnectWithDB, CapabilityClientDeprecateEOF, CapabilityClientLongFlag, CapabilityClientLongPassword, CapabilityClientMultiResults, CapabilityClientMultiStatements, CapabilityClientPluginAuth, CapabilityClientPluginAuthLene...
/* Authors: Whitebox Geospatial Inc. (c) Developer: Dr. <NAME> Created: 20/07/2021 Last Modified: 20/07/2021 License: Whitebox Geospatial Inc. License Agreement */ use std::env; use std::f64; use std::f32::consts::PI; // use std::fs; use std::io::{Error, ErrorKind}; use std::path; use std::str; use std::time::Instant...
use std::collections::BTreeMap; use std::fs::{create_dir, read, read_to_string, remove_dir_all, File, OpenOptions}; use std::io::{stdout, Seek, SeekFrom, Write}; use std::path::PathBuf; use std::time::{SystemTime, UNIX_EPOCH}; use anyhow::{ensure, Context}; use bincode::{deserialize, serialize}; use fil_proofs_tooling...
// Copyright 2018 Parity Technologies (UK) Ltd. // // Permission is hereby granted, free of charge, to any person obtaining a // copy of this software and associated documentation files (the "Software"), // to deal in the Software without restriction, including without limitation // the rights to use, copy, modify, mer...
#[cfg(feature = "parallel")] use rayon::prelude::*; use crate::data::arena::Arena; use crate::dynamics::{Joint, JointSet, RigidBody, RigidBodyChanges}; use crate::geometry::{ColliderSet, InteractionGraph, NarrowPhase}; use parry::partitioning::IndexedData; use std::ops::{Index, IndexMut}; /// The unique handle of a r...
use std::env; fn main() { println!("cargo:rerun-if-changed=build.rs"); let target = env::var("TARGET").unwrap(); let cwd = env::current_dir().unwrap(); println!("cargo:compiler-rt={}", cwd.join("compiler-rt").display()); // Activate libm's unstable features to make full use of Nightly. print...
#[doc = r"Register block"] #[repr(C)] pub struct RegisterBlock { #[doc = "0x00 - LCD Global Control Register"] pub lcd_gctl_reg: crate::Reg<lcd_gctl_reg::LCD_GCTL_REG_SPEC>, #[doc = "0x04 - LCD Global Interrupt Register0"] pub lcd_gint0_reg: crate::Reg<lcd_gint0_reg::LCD_GINT0_REG_SPEC>, #[doc = "0x...
//! The namespace tree structure storing named ty (sub-namespace) and value //! objects, providing name resolution. // FIXME: Cannot derive `Clone` due to rust-lang/rust#26925 #![cfg_attr(feature="clippy", allow(expl_impl_clone_on_copy))] use std::collections::hash_map::{HashMap, Iter as HashMapIter}; use std::cell::...
use gstreamer as gst; use gstreamer_audio as gst_audio; use gstreamer_audio::AudioFormat; use sample::Sample; #[cfg(test)] use byteorder::ByteOrder; use byteorder::{BigEndian, LittleEndian, ReadBytesExt}; use std::collections::vec_deque::VecDeque; use std::io::{Cursor, Read}; #[cfg(test)] use gstreamer::ClockTime;...
use crate::{ gdb_register::*, kernel_abi::{x64, x86, SupportedArch, SupportedArch::*, RD_NATIVE_ARCH}, kernel_metadata::xsave_feature_string, log::LogLevel::LogError, session::task::task_inner::TaskInner, util::{xsave_native_layout, XSaveFeatureLayout, XSaveLayout}, }; use std::{convert::TryInto...
use std::sync::Arc; use crate::algebra::{AdemAlgebra, AdemAlgebraT}; use crate::module::Module; use crate::module::OperationGeneratorPair; use fp::vector::SliceMut; use once::{OnceBiVec, OnceVec}; #[cfg(feature = "json")] use { crate::algebra::JsonAlgebra, fp::vector::Slice, serde_json::{json, Value}, }; ...
// SPDX-License-Identifier: Apache-2.0 use crate::error::GeoffreyError; use rayon::prelude::*; use regex::Regex; use std::collections::HashMap; use std::fs::{self, OpenOptions}; use std::io::{BufRead, BufReader, Write}; use std::path::PathBuf; use std::sync::Mutex; use std::vec::Vec; type Tag = String; #[derive(De...
use std::ffi::c_void; use std::ffi::CString; use std::ptr::null_mut; use std::sync::atomic::AtomicU32; use std::sync::atomic::Ordering; use std::sync::Mutex; use std::sync::RwLock; use imgui::NavInput; use lazy_static::lazy_static; use log::*; use once_cell::sync::OnceCell; use winapi::shared::dxgi::*; use winapi::sh...
//! A "tagstruct" is PulseAudio's central IPC data structure. //! //! A tagstruct is a sequence of type-tagged `Value`s. This module provides parsers for the format //! and writers to easily create tagstruct byte streams. use types::proplist::PropList; use types::sample_spec::{SampleFormat, SampleSpec, CHANNELS_MAX}; ...
use rand::Rng; use regex::Regex; use std::collections::{HashMap, HashSet}; use std::path::Path; use tantivy::collector::{Count, FacetCollector, TopDocs}; use tantivy::query::{ AllQuery, BooleanQuery, Occur, Query, QueryParser, QueryParserError, RegexQuery, TermQuery, }; use tantivy::schema::*; use tantivy::tokenize...
/* Author: <NAME> Description: Pull operational forensics triage from Linux hosts. Build command: cargo build --release Post build: Run "strip" on compiled binary to drastically reduce its size. e.g. "strip lin_fh" GOAL: - cover all persistence mechanisms that can be here: https://a...
#[doc = r"Register block"] #[repr(C)] pub struct RegisterBlock { #[doc = "0x00 - Start generation of keystream. This operation will stop by itself when completed."] pub tasks_ksgen: TASKS_KSGEN, #[doc = "0x04 - Start encryption/decryption. This operation will stop by itself when completed."] pub tasks_c...
use math::*; use uni_gl::*; use std::cell::RefCell; use std::collections::{BTreeMap, BTreeSet, HashMap}; use std::rc::{Rc, Weak}; use std::sync::Arc; use engine::asset::{AssetError, AssetResult, AssetSystem}; use engine::context::EngineContext; use engine::core::{Component, ComponentArena, ComponentBased, G...
// Copyright 2015-2016 <NAME>. // // Permission to use, copy, modify, and/or distribute this software for any // purpose with or without fee is hereby granted, provided that the above // copyright notice and this permission notice appear in all copies. // // THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHORS DISCLAIM ALL...
mod movegen; mod makemove; mod perft; mod io; mod search; mod evaluate; mod uci; use rand::Rng; use std::collections::HashMap; use std::fmt; use crate::pieces::*; use crate::bitboard::{self,Bitboard}; use crate::moves; use crate::version::PROGRAM_NAME; use evaluate::MIRROR64; pub use search::{SearchInfo,GameMode,ben...
use std::borrow::Cow; use std::fmt; use std::ops::RangeInclusive; use enumset::{EnumSet, EnumSetType}; use failure::Fail; use smallvec::SmallVec; use crate::processor::{ProcessValue, SelectorPathItem, SelectorSpec}; use crate::types::Annotated; /// Error for unknown value types. #[derive(Debug, Fail)] #[fail(display...