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

Unified Diff: runtime/bin/dartutils.h

Issue 10379018: Revert "Revert "Implement {Int,Uint}{8,16,32,64} and Float{32,64} typed arrays."" (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 8 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
Index: runtime/bin/dartutils.h
diff --git a/runtime/bin/dartutils.h b/runtime/bin/dartutils.h
index 678f02604eb94b5889ef5fe9ed33b83b3beae942..c8b8b4095d601de57e95795386e02434193bb288 100644
--- a/runtime/bin/dartutils.h
+++ b/runtime/bin/dartutils.h
@@ -131,7 +131,7 @@ class CObject {
bool IsDouble() { return type() == Dart_CObject::kDouble; }
bool IsString() { return type() == Dart_CObject::kString; }
bool IsArray() { return type() == Dart_CObject::kArray; }
- bool IsByteArray() { return type() == Dart_CObject::kByteArray; }
+ bool IsUint8Array() { return type() == Dart_CObject::kUint8Array; }
bool IsTrue() {
return type() == Dart_CObject::kBool && cobject_->value.as_bool;
@@ -157,7 +157,7 @@ class CObject {
static Dart_CObject* NewString(int length);
static Dart_CObject* NewString(const char* str);
static Dart_CObject* NewArray(int length);
- static Dart_CObject* NewByteArray(int length);
+ static Dart_CObject* NewUint8Array(int length);
Dart_CObject* AsApiCObject() { return cobject_; }
@@ -286,9 +286,9 @@ class CObjectArray : public CObject {
};
-class CObjectByteArray : public CObject {
+class CObjectUint8Array : public CObject {
public:
- DECLARE_COBJECT_CONSTRUCTORS(ByteArray)
+ DECLARE_COBJECT_CONSTRUCTORS(Uint8Array)
int Length() const { return cobject_->value.as_byte_array.length; }
uint8_t* Buffer() const { return cobject_->value.as_byte_array.values; }

Powered by Google App Engine
This is Rietveld 408576698