Carvex.LintWarning (Carvex v0.0.1)

Copy Markdown View Source

A diagnostic returned by Carvex.lint/2.

line and column are 1-based. start_offset and end_offset are 0-based UTF-8 byte offsets into the linted source, end exclusive, so the flagged text is binary_part(source, w.start_offset, w.end_offset - w.start_offset). rule is carve-rs's stable rule id, e.g. "unattached-block-attribute".

Summary

Types

t()

@type t() :: %Carvex.LintWarning{
  column: pos_integer(),
  end_offset: non_neg_integer(),
  line: pos_integer(),
  message: String.t(),
  rule: String.t(),
  start_offset: non_neg_integer()
}