namespace AvParser.Core.Parsing;
/// A recoverable problem with a single record. Parsing continues after one of these.
/// 1-based position of the offending item: a line, or a place in a listing.
/// What went wrong, phrased for a user rather than a developer.
public sealed record ParseError(int Index, string Message)
{
///
/// Stable identifier for the kind of failure, or when the message is
/// the only thing on offer.
///
///
/// The domain stays language-free: it produces an English message plus a code, and the UI
/// translates Collect.Error.{Code} with , falling back to
/// . Without this, a Russian UI would still print English error text —
/// and moving the strings themselves into the domain would drag localisation down there.
///
public string? Code { get; init; }
/// Values to substitute into the translated message.
public IReadOnlyList