mirror of
https://codeberg.org/unspeaker/tek.git
synced 2026-03-13 11:50:44 +01:00
view* -> understand*
This commit is contained in:
parent
4aef21f60d
commit
236ee6b810
4 changed files with 16 additions and 16 deletions
16
app/tek.rs
16
app/tek.rs
|
|
@ -1,16 +1,14 @@
|
|||
#![allow(clippy::unit_arg)]
|
||||
#![feature(adt_const_params,
|
||||
associated_type_defaults,
|
||||
closure_lifetime_binder,
|
||||
if_let_guard,
|
||||
impl_trait_in_assoc_type,
|
||||
trait_alias,
|
||||
type_alias_impl_trait,
|
||||
type_changing_struct_update)]
|
||||
#![feature(
|
||||
adt_const_params, associated_type_defaults, closure_lifetime_binder,
|
||||
impl_trait_in_assoc_type, trait_alias, type_alias_impl_trait, type_changing_struct_update
|
||||
)]
|
||||
|
||||
mod tek_struct; pub use self::tek_struct::*;
|
||||
mod tek_trait; pub use self::tek_trait::*;
|
||||
mod tek_type; pub use self::tek_type::*;
|
||||
mod tek_impls;
|
||||
|
||||
extern crate xdg;
|
||||
pub(crate) use ::xdg::BaseDirectories;
|
||||
pub extern crate atomic_float;
|
||||
|
|
@ -133,12 +131,14 @@ pub(crate) fn load_view (views: &Views, name: &impl AsRef<str>, body: &impl Lang
|
|||
views.write().unwrap().insert(name.as_ref().into(), body.src()?.unwrap_or_default().into());
|
||||
Ok(())
|
||||
}
|
||||
|
||||
pub(crate) fn load_mode (modes: &Modes, name: &impl AsRef<str>, body: &impl Language) -> Usually<()> {
|
||||
let mut mode = Mode::default();
|
||||
body.each(|item|mode.add(item))?;
|
||||
modes.write().unwrap().insert(name.as_ref().into(), Arc::new(mode));
|
||||
Ok(())
|
||||
}
|
||||
|
||||
pub(crate) fn load_bind (binds: &Binds, name: &impl AsRef<str>, body: &impl Language) -> Usually<()> {
|
||||
binds.write().unwrap().insert(name.as_ref().into(), Bind::load(body)?);
|
||||
Ok(())
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue