aboutsummaryrefslogtreecommitdiff
path: root/gcc/analyzer/pending-diagnostic.cc
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/analyzer/pending-diagnostic.cc')
-rw-r--r--gcc/analyzer/pending-diagnostic.cc10
1 files changed, 7 insertions, 3 deletions
diff --git a/gcc/analyzer/pending-diagnostic.cc b/gcc/analyzer/pending-diagnostic.cc
index 70dc815..5e95edd 100644
--- a/gcc/analyzer/pending-diagnostic.cc
+++ b/gcc/analyzer/pending-diagnostic.cc
@@ -171,7 +171,7 @@ pending_diagnostic::fixup_location (location_t loc, bool) const
const line_map_macro *macro_map = linemap_check_macro (map);
if (fixup_location_in_macro_p (macro_map->macro))
loc = linemap_resolve_location (line_table, loc,
- LRK_MACRO_EXPANSION_POINT, NULL);
+ LRK_MACRO_EXPANSION_POINT, nullptr);
}
return loc;
}
@@ -185,7 +185,10 @@ pending_diagnostic::add_function_entry_event (const exploded_edge &eedge,
{
const exploded_node *dst_node = eedge.m_dest;
const program_point &dst_point = dst_node->get_point ();
- emission_path->add_event (std::make_unique<function_entry_event> (dst_point));
+ const program_state &dst_state = dst_node->get_state ();
+ emission_path->add_event
+ (std::make_unique<function_entry_event> (dst_point,
+ dst_state));
}
/* Base implementation of pending_diagnostic::add_call_event.
@@ -241,7 +244,8 @@ pending_diagnostic::add_final_event (const state_machine *sm,
(std::make_unique<warning_event>
(loc_info,
enode,
- sm, var, state));
+ sm, var, state,
+ get_final_state ()));
}
} // namespace ana