Skip to main content

CompileCliProgram

Trait CompileCliProgram 

Source
pub trait CompileCliProgram<Compiler> {
    type Commands;

    // Required method
    fn compile_cli_program(self, compiler: &Compiler) -> Self::Commands;
}
Expand description

Compiles a first-order CLI program with a concrete interpreter.

Required Associated Types§

Source

type Commands

The command collection produced by Compiler.

Required Methods§

Source

fn compile_cli_program(self, compiler: &Compiler) -> Self::Commands

Folds the complete first-order program through compiler.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§

Source§

impl<Compiler, Handler, Inputs, Mode, Program, Inner, InnerCommands> CompileCliProgram<Compiler> for Within<Handler, Inputs, Mode, Program>
where Compiler: CliContextAlg<Handler, Inputs, Mode, Inner = Inner, InnerCommands = InnerCommands>, Handler: OperationAlg, Inputs: CliSources<Handler::Args> + CliNamedSources, Program: CompileCliProgram<Inner, Commands = InnerCommands>,

Source§

type Commands = <Compiler as CliContextAlg<Handler, Inputs, Mode>>::Commands

Source§

impl<Compiler, Handler, Inputs, Mode> CompileCliProgram<Compiler> for Command<Handler, Inputs, Mode>
where Compiler: CliOperationAlg<Handler, Inputs, Mode>, Handler: OperationAlg, Inputs: CliSources<Handler::Args>,

Source§

type Commands = <Compiler as CliOperationAlg<Handler, Inputs, Mode>>::Commands

Source§

impl<Compiler, Left, Right, Commands> CompileCliProgram<Compiler> for Merge<Left, Right>
where Compiler: CliCommandsAlg<Commands = Commands>, Left: CompileCliProgram<Compiler, Commands = Commands>, Right: CompileCliProgram<Compiler, Commands = Commands>,

Source§

type Commands = Commands

Source§

impl<Compiler, Program, Commands> CompileCliProgram<Compiler> for Nest<Program>
where Compiler: CliNestAlg<Commands = Commands>, Program: CompileCliProgram<Compiler, Commands = Commands>,

Source§

type Commands = Commands

Source§

impl<Compiler, Program> CompileCliProgram<Compiler> for Named<Program>
where Program: CliProgramAlg<Compiler>,

Source§

type Commands = <Program as CliProgramAlg<Compiler>>::Commands

Source§

impl<Compiler> CompileCliProgram<Compiler> for Empty
where Compiler: CliCommandsAlg,