summaryrefslogtreecommitdiff
path: root/libcpp
diff options
context:
space:
mode:
authordmalcolm <dmalcolm@138bc75d-0d04-0410-961f-82ee72b054a4>2016-09-02 18:00:57 +0000
committerdmalcolm <dmalcolm@138bc75d-0d04-0410-961f-82ee72b054a4>2016-09-02 18:00:57 +0000
commitfe066ce3d8b45a687ddb9ebba6426a3746f3a8ca (patch)
tree796b73d02c02186aeafa76ffa1d0047c651425fa /libcpp
parent9627cfa8887f023d30f31139fef8738976a4fdce (diff)
downloadgcc-fe066ce3d8b45a687ddb9ebba6426a3746f3a8ca.tar.gz
Introduce class edit_context
gcc/ChangeLog: * Makefile.in (OBJS-libcommon): Add edit-context.o. * diagnostic-color.c (color_dict): Add "diff-filename", "diff-hunk", "diff-delete", and "diff-insert". (parse_gcc_colors): Update default value of GCC_COLORS in comment to reflect above changes. * doc/invoke.texi (-fdiagnostics-color): Update description of default GCC_COLORS, and of the supported capabilities. * edit-context.c: New file. * edit-context.h: New file. * input.c (struct fcache): Add field "missing_trailing_newline". (diagnostics_file_cache_forcibly_evict_file): Initialize it to true. (add_file_to_cache_tab): Likewise. (fcache::fcache): Likewise. (get_next_line): Update c->missing_trailing_newline. (location_missing_trailing_newline): New function. * input.h (location_missing_trailing_newline): New decl. * selftest-run-tests.c (selftest::run_tests): Call edit_context_c_tests. * selftest.h (edit_context_c_tests): New decl. libcpp/ChangeLog: * include/line-map.h (rich_location::seen_impossible_fixit_p): New accessor. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@239963 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libcpp')
-rw-r--r--libcpp/ChangeLog5
-rw-r--r--libcpp/include/line-map.h1
2 files changed, 6 insertions, 0 deletions
diff --git a/libcpp/ChangeLog b/libcpp/ChangeLog
index 69abc6802bf..792f76ae3b5 100644
--- a/libcpp/ChangeLog
+++ b/libcpp/ChangeLog
@@ -1,3 +1,8 @@
+2016-09-02 David Malcolm <dmalcolm@redhat.com>
+
+ * include/line-map.h (rich_location::seen_impossible_fixit_p): New
+ accessor.
+
2016-08-31 David Malcolm <dmalcolm@redhat.com>
* include/line-map.h (class fixit_remove): Remove stray decl.
diff --git a/libcpp/include/line-map.h b/libcpp/include/line-map.h
index bef77957ffe..6b3c474a0de 100644
--- a/libcpp/include/line-map.h
+++ b/libcpp/include/line-map.h
@@ -1567,6 +1567,7 @@ class rich_location
unsigned int get_num_fixit_hints () const { return m_fixit_hints.count (); }
fixit_hint *get_fixit_hint (int idx) const { return m_fixit_hints[idx]; }
fixit_hint *get_last_fixit_hint () const;
+ bool seen_impossible_fixit_p () const { return m_seen_impossible_fixit; }
private:
bool reject_impossible_fixit (source_location where);