aboutsummaryrefslogtreecommitdiff
path: root/libstdc++-v3/include/std/numeric
diff options
context:
space:
mode:
authorDavid Malcolm <dmalcolm@redhat.com>2025-05-06 09:26:19 -0400
committerDavid Malcolm <dmalcolm@redhat.com>2025-05-06 09:26:19 -0400
commit52fe9502eb153f87154cfcb6a58ab84164d7e1d9 (patch)
tree4598ea8ba7c27f0ca3c060b3d23615091aab8c6e /libstdc++-v3/include/std/numeric
parent9fb44cc4823106729d086713dd022a4590703a4c (diff)
downloadgcc-52fe9502eb153f87154cfcb6a58ab84164d7e1d9.zip
gcc-52fe9502eb153f87154cfcb6a58ab84164d7e1d9.tar.gz
gcc-52fe9502eb153f87154cfcb6a58ab84164d7e1d9.tar.bz2
json: implement JSON pointer; use it in sarif-replay [PR117988]
This patch extends our json class to track JSON pointers (RFC 6901), and then uses this within sarif-replay to provide logical locations within the JSON when reporting on issues in the SARIF. gcc/ChangeLog: PR sarif-replay/117988 * json.cc (json::pointer::token::token): New ctors. (json::pointer::token::~token): New. (json::pointer::token::operator=): New. (json::object::set): Set the value's m_pointer_token. (json::array::append): Likewise. * json.h (json::pointer::token): New struct. (json::value::get_pointer_token): New accessor. (json::value::m_pointer_token): New field. * libsarifreplay.cc (get_logical_location_kind_for_json_kind): New. (make_logical_location_from_jv): New. (sarif_replayer::report_problem): Set the logical location of the diagnostic. gcc/testsuite/ChangeLog: PR sarif-replay/117988 * sarif-replay.dg/2.1.0-invalid/3.1-not-an-object.sarif: Add expected logical location. * sarif-replay.dg/2.1.0-invalid/3.11.11-missing-arguments-for-placeholders.sarif: Likewise. * sarif-replay.dg/2.1.0-invalid/3.11.11-not-enough-arguments-for-placeholders.sarif: Likewise. * sarif-replay.dg/2.1.0-invalid/3.11.5-unescaped-braces.sarif: Likewise. * sarif-replay.dg/2.1.0-invalid/3.13.2-no-version.sarif: Likewise. * sarif-replay.dg/2.1.0-invalid/3.13.2-version-not-a-string.sarif: Likewise. * sarif-replay.dg/2.1.0-invalid/3.13.4-bad-runs.sarif: Likewise. * sarif-replay.dg/2.1.0-invalid/3.13.4-no-runs.sarif: Likewise. * sarif-replay.dg/2.1.0-invalid/3.13.4-non-object-in-runs.sarif: Likewise. * sarif-replay.dg/2.1.0-invalid/3.27.10-bad-level.sarif: Likewise. * sarif-replay.dg/2.1.0-invalid/3.33.3-index-out-of-range.sarif: Likewise. * sarif-replay.dg/2.1.0-unhandled/3.27.10-none-level.sarif: Likewise. Signed-off-by: David Malcolm <dmalcolm@redhat.com>
Diffstat (limited to 'libstdc++-v3/include/std/numeric')
0 files changed, 0 insertions, 0 deletions