plan.Diagnostic has {Pointer, Severity, Message} — a JSON Pointer string and nothing else.
ogen reports errors with file, line and column via location.Pointer, and recently improved exactly this (fix(libopenapi): attach source positions to parse errors). A generator consuming plans would lose that, making the migration a visible regression in error quality.
libopenapi keeps *yaml.Node positions on the low-level model, so the frontend can capture line/column at conversion time and thread them onto every diagnostic. Also needs a document/file identity once multi-document loading is in play (external $ref targets already come from other documents).
plan.Diagnostichas{Pointer, Severity, Message}— a JSON Pointer string and nothing else.ogen reports errors with file, line and column via
location.Pointer, and recently improved exactly this (fix(libopenapi): attach source positions to parse errors). A generator consuming plans would lose that, making the migration a visible regression in error quality.libopenapi keeps
*yaml.Nodepositions on the low-level model, so the frontend can capture line/column at conversion time and thread them onto every diagnostic. Also needs a document/file identity once multi-document loading is in play (external$reftargets already come from other documents).