struct

PathInfo

Inherits YAML::Serializable < JSON::Serializable < Struct < Value < Object

Constructors

new(path : String, line : Int32 | Nil)

Line numbers here are 1-based, so 0 is not a line — it is how a handful of analyzers spelled "this endpoint came from that file, but there is no line to point at" (HAR / mitmproxy captures have no source line at all; akka's nested route DSL had none to hand). nil is the representation the rest of the codebase already uses for that, and every consumer branches on it: the plain and HTML reports printed a meaningless (line 0), and SARIF emitted region.startLine: 0, which the format forbids — startLine must be a positive integer, so the report failed validation.

Normalized here rather than at the three call sites so a future analyzer can't reintroduce it.

Source
new(path : String)
Source
new(*, __pull_for_json_serializable pull : JSON::PullParser)
Source
new(*, __context_for_yaml_serializable ctx : YAML::ParseContext, __node_for_yaml_serializable node : YAML::Nodes::Node)
Source

Instance methods

==(other : PathInfo) : Bool
Source
line
Source
line=(line : Int32 | Nil)
Source
path
Source
path=(path : String)
Source