From: Ian Jackson Date: Sun, 14 Feb 2021 19:30:46 +0000 (+0000) Subject: wdt: Type alias for GameSpec X-Git-Tag: otter-0.4.0~489 X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=commitdiff_plain;h=63715ac3ac2fa2d1dc4750e2b15552f5a5360368;p=otter.git wdt: Type alias for GameSpec Signed-off-by: Ian Jackson --- diff --git a/wdriver.rs b/wdriver.rs index 5cbed861..a18862d4 100644 --- a/wdriver.rs +++ b/wdriver.rs @@ -48,7 +48,7 @@ pub use otter::commands::{MgmtGameUpdateMode}; pub use otter::gamestate::{self, Generation}; pub use otter::global::InstanceName; pub use otter::mgmtchannel::MgmtChannel; -pub use otter::spec::{Coord, Pos, PosC}; +pub use otter::spec::{Coord, GameSpec, Pos, PosC}; pub use otter::toml_de; pub use otter::ui::{AbbrevPresentationLayout, PresentationLayout}; @@ -653,7 +653,7 @@ impl DirSubst { } #[throws(AE)] - pub fn game_spec_data(&self) -> otter::spec::GameSpec { + pub fn game_spec_data(&self) -> GameSpec { let path = self.game_spec_path()?; (||{ let data = fs::read(&path).context("read")?; @@ -1377,7 +1377,7 @@ pub struct UsualSetup { pub inst: Instance, pub alice: Window, pub bob: Window, - pub spec: otter::spec::GameSpec, + pub spec: GameSpec, } impl UsualSetup { diff --git a/wdriver/wdt-simple.rs b/wdriver/wdt-simple.rs index 707ea4a8..818aca1f 100644 --- a/wdriver/wdt-simple.rs +++ b/wdriver/wdt-simple.rs @@ -8,7 +8,7 @@ struct Ctx { su: Setup, alice: Window, bob: Window, - spec: otter::spec::GameSpec, + spec: GameSpec, } ctx_with_setup!{Ctx}