Remove V8_WARN_UNUSED_RESULT for simple getters.

R=bmeurer@chromium.org

Review URL: https://codereview.chromium.org/23629031

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@16624 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
This commit is contained in:
mstarzinger@chromium.org 2013-09-10 15:03:17 +00:00
parent 448d98e19d
commit 1c91d00bf7
6 changed files with 16 additions and 16 deletions

View File

@ -100,7 +100,7 @@ class CPU V8_FINAL BASE_EMBEDDED {
bool has_vfp3_d32() const { return has_vfp3_d32_; } bool has_vfp3_d32() const { return has_vfp3_d32_; }
// Returns the number of processors online. // Returns the number of processors online.
static int NumberOfProcessorsOnline() V8_WARN_UNUSED_RESULT; static int NumberOfProcessorsOnline();
// Initializes the cpu architecture support. Called once at VM startup. // Initializes the cpu architecture support. Called once at VM startup.
static void SetUp(); static void SetUp();

View File

@ -105,10 +105,10 @@ class ConditionVariable V8_FINAL {
}; };
#endif #endif
NativeHandle& native_handle() V8_WARN_UNUSED_RESULT { NativeHandle& native_handle() {
return native_handle_; return native_handle_;
} }
const NativeHandle& native_handle() const V8_WARN_UNUSED_RESULT { const NativeHandle& native_handle() const {
return native_handle_; return native_handle_;
} }

View File

@ -87,7 +87,7 @@ class ElapsedTimer V8_FINAL BASE_EMBEDDED {
// Returns the time elapsed since the previous start. This method may only // Returns the time elapsed since the previous start. This method may only
// be called on a previously started timer. // be called on a previously started timer.
TimeDelta Elapsed() const V8_WARN_UNUSED_RESULT { TimeDelta Elapsed() const {
ASSERT(IsStarted()); ASSERT(IsStarted());
TimeDelta elapsed = Now() - start_ticks_; TimeDelta elapsed = Now() - start_ticks_;
ASSERT(elapsed.InMicroseconds() >= 0); ASSERT(elapsed.InMicroseconds() >= 0);
@ -97,13 +97,13 @@ class ElapsedTimer V8_FINAL BASE_EMBEDDED {
// Returns |true| if the specified |time_delta| has elapsed since the // Returns |true| if the specified |time_delta| has elapsed since the
// previous start, or |false| if not. This method may only be called on // previous start, or |false| if not. This method may only be called on
// a previously started timer. // a previously started timer.
bool HasExpired(TimeDelta time_delta) const V8_WARN_UNUSED_RESULT { bool HasExpired(TimeDelta time_delta) const {
ASSERT(IsStarted()); ASSERT(IsStarted());
return Elapsed() >= time_delta; return Elapsed() >= time_delta;
} }
private: private:
V8_INLINE(static TimeTicks Now()) V8_WARN_UNUSED_RESULT { V8_INLINE(static TimeTicks Now()) {
TimeTicks now = TimeTicks::HighResNow(); TimeTicks now = TimeTicks::HighResNow();
ASSERT(!now.IsNull()); ASSERT(!now.IsNull());
return now; return now;

View File

@ -81,10 +81,10 @@ class Mutex V8_FINAL {
typedef CRITICAL_SECTION NativeHandle; typedef CRITICAL_SECTION NativeHandle;
#endif #endif
NativeHandle& native_handle() V8_WARN_UNUSED_RESULT { NativeHandle& native_handle() {
return native_handle_; return native_handle_;
} }
const NativeHandle& native_handle() const V8_WARN_UNUSED_RESULT { const NativeHandle& native_handle() const {
return native_handle_; return native_handle_;
} }
@ -177,10 +177,10 @@ class RecursiveMutex V8_FINAL {
// The implementation-defined native handle type. // The implementation-defined native handle type.
typedef Mutex::NativeHandle NativeHandle; typedef Mutex::NativeHandle NativeHandle;
NativeHandle& native_handle() V8_WARN_UNUSED_RESULT { NativeHandle& native_handle() {
return native_handle_; return native_handle_;
} }
const NativeHandle& native_handle() const V8_WARN_UNUSED_RESULT { const NativeHandle& native_handle() const {
return native_handle_; return native_handle_;
} }

View File

@ -80,10 +80,10 @@ class Semaphore V8_FINAL {
typedef HANDLE NativeHandle; typedef HANDLE NativeHandle;
#endif #endif
NativeHandle& native_handle() V8_WARN_UNUSED_RESULT { NativeHandle& native_handle() {
return native_handle_; return native_handle_;
} }
const NativeHandle& native_handle() const V8_WARN_UNUSED_RESULT { const NativeHandle& native_handle() const {
return native_handle_; return native_handle_;
} }

View File

@ -66,11 +66,11 @@ class Socket V8_FINAL {
// Set the value of the SO_REUSEADDR socket option. // Set the value of the SO_REUSEADDR socket option.
bool SetReuseAddress(bool reuse_address); bool SetReuseAddress(bool reuse_address);
V8_INLINE(bool IsValid()) const V8_WARN_UNUSED_RESULT { V8_INLINE(bool IsValid()) const {
return native_handle_ != kInvalidNativeHandle; return native_handle_ != kInvalidNativeHandle;
} }
static int GetLastError() V8_WARN_UNUSED_RESULT; static int GetLastError();
// The implementation-defined native handle type. // The implementation-defined native handle type.
#if V8_OS_POSIX #if V8_OS_POSIX
@ -81,10 +81,10 @@ class Socket V8_FINAL {
static const NativeHandle kInvalidNativeHandle = INVALID_SOCKET; static const NativeHandle kInvalidNativeHandle = INVALID_SOCKET;
#endif #endif
NativeHandle& native_handle() V8_WARN_UNUSED_RESULT { NativeHandle& native_handle() {
return native_handle_; return native_handle_;
} }
const NativeHandle& native_handle() const V8_WARN_UNUSED_RESULT { const NativeHandle& native_handle() const {
return native_handle_; return native_handle_;
} }