aboutsummaryrefslogtreecommitdiff
path: root/gcc/tree-diagnostic-path.cc
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/tree-diagnostic-path.cc')
-rw-r--r--gcc/tree-diagnostic-path.cc5
1 files changed, 3 insertions, 2 deletions
diff --git a/gcc/tree-diagnostic-path.cc b/gcc/tree-diagnostic-path.cc
index 381a49c..82b3c2d 100644
--- a/gcc/tree-diagnostic-path.cc
+++ b/gcc/tree-diagnostic-path.cc
@@ -493,7 +493,7 @@ default_tree_diagnostic_path_printer (diagnostic_context *context,
doesn't have access to trees (for m_fndecl). */
json::value *
-default_tree_make_json_for_path (diagnostic_context *,
+default_tree_make_json_for_path (diagnostic_context *context,
const diagnostic_path *path)
{
json::array *path_array = new json::array ();
@@ -504,7 +504,8 @@ default_tree_make_json_for_path (diagnostic_context *,
json::object *event_obj = new json::object ();
if (event.get_location ())
event_obj->set ("location",
- json_from_expanded_location (event.get_location ()));
+ json_from_expanded_location (context,
+ event.get_location ()));
label_text event_text (event.get_desc (false));
event_obj->set ("description", new json::string (event_text.m_buffer));
event_text.maybe_free ();