lib.rs
61 lines
| 2.0 KiB
| application/rls-services+xml
|
RustLexer
Georges Racinet
|
r44455 | // Copyright 2018-2020 Georges Racinet <georges.racinet@octobus.net> | ||
// and Mercurial contributors | ||||
Georges Racinet
|
r40307 | // | ||
// This software may be used and distributed according to the terms of the | ||||
// GNU General Public License version 2 or any later version. | ||||
Simon Sapin
|
r47172 | |||
Georges Racinet
|
r40307 | mod ancestors; | ||
Georges Racinet on ishtar.racinet.fr
|
r41278 | pub mod dagops; | ||
Simon Sapin
|
r47167 | pub mod errors; | ||
Raphaël Gomès
|
r50383 | pub mod narrow; | ||
Raphaël Gomès
|
r50380 | pub mod sparse; | ||
pacien
|
r49351 | pub use ancestors::{AncestorsIterator, MissingAncestors}; | ||
Simon Sapin
|
r47871 | pub mod dirstate; | ||
Georges Racinet
|
r42355 | pub mod discovery; | ||
Pulkit Goyal
|
r48199 | pub mod exit_codes; | ||
Raphaël Gomès
|
r53063 | pub mod fncache; | ||
Simon Sapin
|
r46536 | pub mod requirements; | ||
Raphaël Gomès
|
r42489 | pub mod testing; // unconditionally built, for use from integration tests | ||
Raphaël Gomès
|
r53197 | |||
// Export very common type to make discovery easier | ||||
pub use dirstate::DirstateParents; | ||||
r46556 | pub mod copy_tracing; | |||
Spencer Baugh
|
r51759 | pub mod filepatterns; | ||
Raphaël Gomès
|
r43742 | pub mod matchers; | ||
Simon Sapin
|
r46782 | pub mod repo; | ||
Georges Racinet
|
r44457 | pub mod revlog; | ||
Raphaël Gomès
|
r53075 | // Export very common types to make discovery easier | ||
pub use revlog::{ | ||||
BaseRevision, Graph, GraphError, Node, NodePrefix, Revision, | ||||
UncheckedRevision, NULL_NODE, NULL_NODE_ID, NULL_REVISION, | ||||
WORKING_DIRECTORY_HEX, WORKING_DIRECTORY_REVISION, | ||||
}; | ||||
Arseniy Alekseyev
|
r50789 | pub mod checkexec; | ||
Raphaël Gomès
|
r46803 | pub mod config; | ||
Simon Sapin
|
r49245 | pub mod lock; | ||
Simon Sapin
|
r47341 | pub mod logging; | ||
Antoine Cezar
|
r45501 | pub mod operations; | ||
Raphaël Gomès
|
r52934 | pub mod progress; | ||
Simon Sapin
|
r47162 | pub mod revset; | ||
Raphaël Gomès
|
r53057 | pub mod transaction; | ||
Raphaël Gomès
|
r52953 | pub mod update; | ||
Raphaël Gomès
|
r42829 | pub mod utils; | ||
Simon Sapin
|
r48764 | pub mod vfs; | ||
Raphaël Gomès
|
r53110 | use std::{collections::HashMap, sync::atomic::AtomicBool}; | ||
Raphaël Gomès
|
r44278 | use twox_hash::RandomXxHashBuilder64; | ||
Georges Racinet
|
r40307 | |||
Raphaël Gomès
|
r53110 | /// Used to communicate with threads spawned from code within this crate that | ||
/// they should stop their work (SIGINT was received). | ||||
pub static INTERRUPT_RECEIVED: AtomicBool = AtomicBool::new(false); | ||||
Raphaël Gomès
|
r42514 | pub type LineNumber = usize; | ||
Raphaël Gomès
|
r44278 | /// Rust's default hasher is too slow because it tries to prevent collision | ||
/// attacks. We are not concerned about those: if an ill-minded person has | ||||
/// write access to your repository, you have other issues. | ||||
pub type FastHashMap<K, V> = HashMap<K, V, RandomXxHashBuilder64>; | ||||
Simon Sapin
|
r49805 | // TODO: should this be the default `FastHashMap` for all of hg-core, not just | ||
Raphaël Gomès
|
r53195 | // dirstate? How does XxHash compare with AHash, hashbrown’s default? | ||
Simon Sapin
|
r49805 | pub type FastHashbrownMap<K, V> = | ||
hashbrown::HashMap<K, V, RandomXxHashBuilder64>; | ||||