| Index: third_party/WebKit/Source/wtf/IntegralTypedArrayBase.h
|
| diff --git a/third_party/WebKit/Source/wtf/IntegralTypedArrayBase.h b/third_party/WebKit/Source/wtf/IntegralTypedArrayBase.h
|
| index f5ba6141e73417c649dd1a6039930e9341a1d26c..379bc8799f05fa29c1103588a8eadfadf6e1ee1a 100644
|
| --- a/third_party/WebKit/Source/wtf/IntegralTypedArrayBase.h
|
| +++ b/third_party/WebKit/Source/wtf/IntegralTypedArrayBase.h
|
| @@ -37,27 +37,27 @@ namespace WTF {
|
| // (non-floating-point) values.
|
| template <typename T>
|
| class IntegralTypedArrayBase : public TypedArrayBase<T> {
|
| -public:
|
| - void set(unsigned index, double value)
|
| - {
|
| - if (index >= TypedArrayBase<T>::m_length)
|
| - return;
|
| - if (std::isnan(value)) // Clamp NaN to 0
|
| - value = 0;
|
| - // The double cast is necessary to get the correct wrapping
|
| - // for out-of-range values with Int32Array and Uint32Array.
|
| - TypedArrayBase<T>::data()[index] = static_cast<T>(static_cast<int64_t>(value));
|
| - }
|
| -
|
| -protected:
|
| - IntegralTypedArrayBase(PassRefPtr<ArrayBuffer> buffer, unsigned byteOffset, unsigned length)
|
| - : TypedArrayBase<T>(buffer, byteOffset, length)
|
| - {
|
| - }
|
| + public:
|
| + void set(unsigned index, double value) {
|
| + if (index >= TypedArrayBase<T>::m_length)
|
| + return;
|
| + if (std::isnan(value)) // Clamp NaN to 0
|
| + value = 0;
|
| + // The double cast is necessary to get the correct wrapping
|
| + // for out-of-range values with Int32Array and Uint32Array.
|
| + TypedArrayBase<T>::data()[index] =
|
| + static_cast<T>(static_cast<int64_t>(value));
|
| + }
|
| +
|
| + protected:
|
| + IntegralTypedArrayBase(PassRefPtr<ArrayBuffer> buffer,
|
| + unsigned byteOffset,
|
| + unsigned length)
|
| + : TypedArrayBase<T>(buffer, byteOffset, length) {}
|
| };
|
|
|
| -} // namespace WTF
|
| +} // namespace WTF
|
|
|
| using WTF::IntegralTypedArrayBase;
|
|
|
| -#endif // IntegralTypedArrayBase_h
|
| +#endif // IntegralTypedArrayBase_h
|
|
|