Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2295)

Unified Diff: Source/wtf/Uint8ClampedArray.h

Issue 1180713004: Remove unused code from WTF TypedArrays (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/wtf/Uint8Array.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/wtf/Uint8ClampedArray.h
diff --git a/Source/wtf/Uint8ClampedArray.h b/Source/wtf/Uint8ClampedArray.h
index ef6797de446846de75fdd12d932aee1802b658f0..abefd28aee17a6cc4f7e9adb31c616ee1d794953 100644
--- a/Source/wtf/Uint8ClampedArray.h
+++ b/Source/wtf/Uint8ClampedArray.h
@@ -39,21 +39,9 @@ public:
static inline PassRefPtr<Uint8ClampedArray> create(const unsigned char* array, unsigned length);
static inline PassRefPtr<Uint8ClampedArray> create(PassRefPtr<ArrayBuffer>, unsigned byteOffset, unsigned length);
- // Should only be used when it is known the entire array will be filled. Do
- // not return these results directly to JavaScript without filling first.
- static inline PassRefPtr<Uint8ClampedArray> createUninitialized(unsigned length);
-
- // It's only needed to potentially call this method if the array
- // was created uninitialized -- the default initialization paths
- // zero the allocated memory.
- inline void zeroFill();
-
using TypedArrayBase<unsigned char>::set;
inline void set(unsigned index, double value);
- inline PassRefPtr<Uint8ClampedArray> subarray(int start) const;
- inline PassRefPtr<Uint8ClampedArray> subarray(int start, int end) const;
-
virtual ViewType type() const override
{
return TypeUint8Clamped;
@@ -82,16 +70,6 @@ PassRefPtr<Uint8ClampedArray> Uint8ClampedArray::create(PassRefPtr<ArrayBuffer>
return TypedArrayBase<unsigned char>::create<Uint8ClampedArray>(buffer, byteOffset, length);
}
-PassRefPtr<Uint8ClampedArray> Uint8ClampedArray::createUninitialized(unsigned length)
-{
- return TypedArrayBase<unsigned char>::createUninitialized<Uint8ClampedArray>(length);
-}
-
-void Uint8ClampedArray::zeroFill()
-{
- zeroRange(0, length());
-}
-
void Uint8ClampedArray::set(unsigned index, double value)
{
if (index >= m_length)
@@ -108,16 +86,6 @@ Uint8ClampedArray::Uint8ClampedArray(PassRefPtr<ArrayBuffer> buffer, unsigned by
{
}
-PassRefPtr<Uint8ClampedArray> Uint8ClampedArray::subarray(int start) const
-{
- return subarray(start, length());
-}
-
-PassRefPtr<Uint8ClampedArray> Uint8ClampedArray::subarray(int start, int end) const
-{
- return subarrayImpl<Uint8ClampedArray>(start, end);
-}
-
} // namespace WTF
using WTF::Uint8ClampedArray;
« no previous file with comments | « Source/wtf/Uint8Array.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698