From: Ian Jackson Date: Thu, 29 Apr 2021 00:17:33 +0000 (+0100) Subject: otter(1): Provide SpecRaw X-Git-Tag: otter-0.6.0~499 X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=commitdiff_plain;h=a9eea3f4e82a74e51dcfb6b1bb1dfa808cb8d9b1;p=otter.git otter(1): Provide SpecRaw Not used yet. Signed-off-by: Ian Jackson --- diff --git a/src/bin/otter.rs b/src/bin/otter.rs index 7f7522d2..91cae8bb 100644 --- a/src/bin/otter.rs +++ b/src/bin/otter.rs @@ -575,6 +575,16 @@ impl SpecParse for SpecParseToml { } } impl SpecParseToml { pub fn new() -> Self { Self(default()) } } +#[allow(dead_code)] +struct SpecRaw(pub PhantomData); +impl SpecParse for SpecRaw { + type T = String; + type S = T; + #[throws(AE)] + fn parse(buf: String) -> String { buf } +} +#[allow(dead_code)] +impl SpecRaw { pub fn new() -> Self { Self(default()) } } #[throws(AE)] fn read_spec(ma: &MainOpts, specname: &str, _: P) -> P::T