pub mod help;
pub mod sys;
use sys::{app::App, log::Log};
pub fn run(name: &str, version: &str, desc: &str) {
let app = match App::new(name, version, desc) {
Some(a) => a,
None => return,
};
Log::info(200, None);
app.run();
Log::info(201, None);
}
pub const TINY_KEY: &str = "tinysession";
pub const EMPTY_ID: i64 = -3750763034362895579;
pub const INDEX_ID: i64 = -8948777187306027381;
pub const ERR_ID: i64 = -4396352056573698612;
pub const NOT_FOUND_ID: i64 = -1573091631220776463;
#[inline]
fn fnv1a_64(text: &str) -> i64 {
let mut hash: u64 = 0xcbf29ce484222325;
let prime: u64 = 0x100000001b3;
for c in text.bytes() {
hash ^= u64::from(c);
hash = hash.wrapping_mul(prime);
}
unsafe { *(&hash as *const u64 as *const i64) }
}