Skip to main content

run_check

Function run_check 

Source
pub fn run_check(
    prog: &str,
    input: &Path,
    short: bool,
    fix: Option<&[String]>,
    each: bool,
) -> ExitCode
Expand description

The check command body run by bynk check: a directory routes through project::check_project (finding #64 — non-bailing, so a structural error anywhere does not hide diagnostics elsewhere the way compile_project’s bail-fast Mode::Build would), a single file through bynk_emit::check_with_warnings. short selects the one-line --format short rendering. prog prefixes messages (bynk: …).

#2642: fix first applies the machine-applicable suggestions (fix) to the input, or to each workspace member in turn, then reports what remains as an ordinary check does. A refused or failed fix fails the run.

#3537: fix is None for no fixing, Some(&[]) for --fix (every diagnostic check shows) and Some(codes) for --fix=<code>,…, which takes only those codes’ fixes. An unknown code is refused before any work.