summaryrefslogtreecommitdiff
path: root/src/base/bitunion.hh
diff options
context:
space:
mode:
authorAndreas Hansson <andreas.hansson@arm.com>2016-01-11 05:52:20 -0500
committerAndreas Hansson <andreas.hansson@arm.com>2016-01-11 05:52:20 -0500
commit12eb0343784f52994110df7e7fce4a0b639a6ec3 (patch)
tree12ff1c51b8051bb7e7d889eed499bee0dcd4cd1e /src/base/bitunion.hh
parent7661f1c2bf2b45603264076fabce2eb42373cd18 (diff)
downloadgem5-12eb0343784f52994110df7e7fce4a0b639a6ec3.tar.xz
scons: Enable -Wextra by default
Make best use of the compiler, and enable -Wextra as well as -Wall. There are a few issues that had to be resolved, but they are all trivial.
Diffstat (limited to 'src/base/bitunion.hh')
-rw-r--r--src/base/bitunion.hh12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/base/bitunion.hh b/src/base/bitunion.hh
index c4b67b073..35448ed24 100644
--- a/src/base/bitunion.hh
+++ b/src/base/bitunion.hh
@@ -89,7 +89,7 @@ namespace BitfieldBackend
"Bitfield ranges must be specified as <msb, lsb>");
public:
- operator const uint64_t () const
+ operator uint64_t () const
{
return this->getBits(first, last);
}
@@ -129,7 +129,7 @@ namespace BitfieldBackend
class BitfieldWO : public Bitfield<first, last>
{
private:
- operator const uint64_t () const;
+ operator uint64_t () const;
public:
using Bitfield<first, last>::operator=;
@@ -148,7 +148,7 @@ namespace BitfieldBackend
class SignedBitfield : public BitfieldBase<Type>
{
public:
- operator const int64_t () const
+ operator int64_t () const
{
return sext<first - last + 1>(this->getBits(first, last));
}
@@ -188,7 +188,7 @@ namespace BitfieldBackend
class SignedBitfieldWO : public SignedBitfield<first, last>
{
private:
- operator const int64_t () const;
+ operator int64_t () const;
public:
using SignedBitfield<first, last>::operator=;
@@ -304,10 +304,10 @@ namespace BitfieldBackend
//do so.
#define EndSubBitUnion(name) \
}; \
- inline operator const __DataType () const \
+ inline operator __DataType () const \
{ return __data; } \
\
- inline const __DataType operator = (const __DataType & _data) \
+ inline __DataType operator = (const __DataType & _data) \
{ return __data = _data;} \
} name;