#![cfg_attr(docsrs, feature(doc_cfg))]
mod autocmd;
mod buffer;
mod error;
mod extmark;
mod ffi;
mod global;
pub mod opts;
pub(crate) mod serde_utils;
mod tabpage;
mod trait_utils;
pub mod types;
pub(crate) mod utils;
mod vimscript;
mod win_config;
mod window;
pub use autocmd::*;
pub use buffer::*;
pub use error::Error;
use error::Result;
pub use extmark::*;
pub use global::*;
pub use tabpage::*;
pub use trait_utils::*;
pub use vimscript::*;
pub use win_config::*;
pub use window::*;
const INTERNAL_CALL_MASK: u64 = 1u64 << (std::mem::size_of::<u64>() * 8 - 1);
const VIML_INTERNAL_CALL: u64 = INTERNAL_CALL_MASK;
const LUA_INTERNAL_CALL: u64 = VIML_INTERNAL_CALL + 1;
macro_rules! choose {
($err:expr, ()) => {
if $err.is_err() {
Err($err.into())
} else {
Ok(())
}
};
($err:expr, $other:expr) => {
if $err.is_err() {
Err($err.into())
} else {
$other
}
};
}
pub(crate) use choose;