diff options
author | dmalcolm <dmalcolm@138bc75d-0d04-0410-961f-82ee72b054a4> | 2016-12-09 14:34:48 +0000 |
---|---|---|
committer | dmalcolm <dmalcolm@138bc75d-0d04-0410-961f-82ee72b054a4> | 2016-12-09 14:34:48 +0000 |
commit | 8dfbae2b12f2229ef1bf243a03f142759c2340a9 (patch) | |
tree | ec488524deffd81934463b0cea19f04ff7637e0c /gcc | |
parent | 4ac9c7e96164682a027509f5586c933fe2ab35a4 (diff) | |
download | gcc-8dfbae2b12f2229ef1bf243a03f142759c2340a9.tar.gz |
Prevent use of MEM_* attr accessor macros as lvalues
gcc/ChangeLog:
* rtl.h (get_mem_attrs): Add "const" qualifier to returned
pointer.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@243487 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/ChangeLog | 5 | ||||
-rw-r--r-- | gcc/rtl.h | 2 |
2 files changed, 6 insertions, 1 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index d2e5f478cc4..91dfc18bf9f 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +2016-12-09 David Malcolm <dmalcolm@redhat.com> + + * rtl.h (get_mem_attrs): Add "const" qualifier to returned + pointer. + 2016-12-09 Nathan Sidwell <nathan@acm.org> PR C++/78550 diff --git a/gcc/rtl.h b/gcc/rtl.h index a5efa282a15..4f0efa61aa8 100644 --- a/gcc/rtl.h +++ b/gcc/rtl.h @@ -3355,7 +3355,7 @@ extern struct target_rtl *this_target_rtl; #ifndef GENERATOR_FILE /* Return the attributes of a MEM rtx. */ -static inline struct mem_attrs * +static inline const struct mem_attrs * get_mem_attrs (const_rtx x) { struct mem_attrs *attrs; |