projects
/
gcc.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
9855e8a
)
vec: Silence clang warning
author
Richard Sandiford
<richard.sandiford@arm.com>
Sun, 13 Dec 2020 10:41:06 +0000
(10:41 +0000)
committer
Richard Sandiford
<richard.sandiford@arm.com>
Sun, 13 Dec 2020 10:41:06 +0000
(10:41 +0000)
I noticed during compatibility testing that clang warns that this
operator won't be implicitly const in C++14 onwards.
gcc/
* vec.h (vnull::operator vec<T, A, L>): Make const.
gcc/vec.h
patch
|
blob
|
history
diff --git
a/gcc/vec.h
b/gcc/vec.h
index 09166f1bce6bb24891e845010a2cf1c4905f0ad8..31574b49c25c406b76b0f4d42f2569c0f6402f4a 100644
(file)
--- a/
gcc/vec.h
+++ b/
gcc/vec.h
@@
-550,7
+550,7
@@
vec_copy_construct (T *dst, const T *src, unsigned n)
struct vnull
{
template <typename T, typename A, typename L>
- CONSTEXPR operator vec<T, A, L> () { return vec<T, A, L>(); }
+ CONSTEXPR operator vec<T, A, L> ()
const
{ return vec<T, A, L>(); }
};
extern vnull vNULL;