fn target(&mut self) -> anyhow::Result<Target<'a>> {
        let name = self.name()?;
        self.dependencies_header("input")?;
        self.check_count(b' ', 1, "after 'input'")?;
        let rule = self.line().into();
        let inputs = self.dependencies()?;
        self.dependencies_header("outputs")?;
        if self.line() != b"" {
            err("extra bytes on line after 'outputs':")?;
        }
        let outputs = self.dependencies()?;
        if !outputs.implicit.is_empty() {
            err("implicit '|' outputs are not allowed")?;
        }
        if !outputs.ordered.is_empty() {
            err("ordered '||' outputs are not allowed")?;
        }
        let outputs = outputs.normal;
        Target {
            name,
            rule,
            inputs,
            outputs,
        }.apply(Ok)
    }
/// Parse a ninja target, at least what `ninja -t query` outputs.
///
/// The expected form is:
/// ```ninja
/// {target}:
///   input: {rule}
///     {input}
///     ...
///     | {implicit_input}
///     ...
///     || {order_input}
///     ...
///   outputs:
///     {output}
///     ...
/// ```
Parse a ninja target, at least what `ninja -t query` outputs.
Parse a ninja target at least what ` ninja - t query ` outputs .
fn target(&mut self) -> anyhow::Result<Target<'a>> {
        let name = self.name()?;
        self.dependencies_header("input")?;
        self.check_count(b' ', 1, "after 'input'")?;
        let rule = self.line().into();
        let inputs = self.dependencies()?;
        self.dependencies_header("outputs")?;
        if self.line() != b"" {
            err("extra bytes on line after 'outputs':")?;
        }
        let outputs = self.dependencies()?;
        if !outputs.implicit.is_empty() {
            err("implicit '|' outputs are not allowed")?;
        }
        if !outputs.ordered.is_empty() {
            err("ordered '||' outputs are not allowed")?;
        }
        let outputs = outputs.normal;
        Target {
            name,
            rule,
            inputs,
            outputs,
        }.apply(Ok)
    }
fn target ( & mut self ) -> anyhow :: Result < Target < ' a > > { let name = self . name ( ) ? ; self . dependencies_header ( " " ) ? ; self . check_count ( b' ' , 1 , " " ) ? ; let rule = self . line ( ) . into ( ) ; let inputs = self . dependencies ( ) ? ; self . dependencies_header ( " " ) ? ; if self . line ( ) != b" " { err ( " " ) ? ; } let outputs = self . dependencies ( ) ? ; if ! outputs . implicit . is_empty ( ) { err ( " " ) ? ; } if ! outputs . ordered . is_empty ( ) { err ( " " ) ? ; } let outputs = outputs . normal ; Target { name , rule , inputs , outputs , } . apply ( Ok ) }
Parse a ninja target, at least what `ninja -t query` outputs.
Parse a ninja target at least what ` ninja - t query ` outputs .
&mut self