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

Unified Diff: src/wasm/wasm-objects.h

Issue 2977543002: [wasm] Allow full u32 range for table maximum in WebAssembly.Table constructor. (Closed)
Patch Set: [wasm] Allow full u32 range for table maximum in WebAssembly.Table constructor. Created 3 years, 5 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 | « src/wasm/wasm-js.cc ('k') | src/wasm/wasm-objects.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/wasm/wasm-objects.h
diff --git a/src/wasm/wasm-objects.h b/src/wasm/wasm-objects.h
index a6c0babad98d3ea100ea4d494e82b92e40a310c0..fa57bca794dccdf7074804813a645644cb6f736f 100644
--- a/src/wasm/wasm-objects.h
+++ b/src/wasm/wasm-objects.h
@@ -77,7 +77,8 @@ class WasmTableObject : public JSObject {
DECL_CAST(WasmTableObject)
DECL_ACCESSORS(functions, FixedArray)
- DECL_INT_ACCESSORS(maximum_length)
+ // TODO(titzer): introduce DECL_I64_ACCESSORS macro
+ DECL_ACCESSORS(maximum_length, Object)
DECL_ACCESSORS(dispatch_tables, FixedArray)
enum { // --
@@ -93,7 +94,7 @@ class WasmTableObject : public JSObject {
DEF_OFFSET(DispatchTables)
inline uint32_t current_length() { return functions()->length(); }
- inline bool has_maximum_length() { return maximum_length() >= 0; }
+ inline bool has_maximum_length() { return maximum_length()->Number() >= 0; }
void grow(Isolate* isolate, uint32_t count);
static Handle<WasmTableObject> New(Isolate* isolate, uint32_t initial,
@@ -680,7 +681,7 @@ ACCESSORS(WasmModuleObject, compiled_module, WasmCompiledModule,
// WasmTableObject
ACCESSORS(WasmTableObject, functions, FixedArray, kFunctionsOffset)
-SMI_ACCESSORS(WasmTableObject, maximum_length, kMaximumLengthOffset)
+ACCESSORS(WasmTableObject, maximum_length, Object, kMaximumLengthOffset)
ACCESSORS(WasmTableObject, dispatch_tables, FixedArray, kDispatchTablesOffset)
// WasmMemoryObject
« no previous file with comments | « src/wasm/wasm-js.cc ('k') | src/wasm/wasm-objects.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698