diff options
author | Bert Belder <bertbelder@gmail.com> | 2020-11-25 00:38:23 +0100 |
---|---|---|
committer | Bert Belder <bertbelder@gmail.com> | 2020-11-25 01:15:14 +0100 |
commit | 8d12653738066facfc228b1d0d9e31b76c6d9de0 (patch) | |
tree | e45c90cc79607fd5c8a29d0231f9cc43353399ac /core/ops.rs | |
parent | 605874ee98b52f5de7d1d1284507d5a9cb9eea9d (diff) |
core: implement 'AsyncRefCell' and 'ResourceTable2' (#8273)
Diffstat (limited to 'core/ops.rs')
-rw-r--r-- | core/ops.rs | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/core/ops.rs b/core/ops.rs index ed74ce873..bf10d3d86 100644 --- a/core/ops.rs +++ b/core/ops.rs @@ -34,6 +34,7 @@ pub enum Op { /// Maintains the resources and ops inside a JS runtime. pub struct OpState { pub resource_table: crate::ResourceTable, + pub resource_table_2: crate::resources2::ResourceTable, pub op_table: OpTable, pub get_error_class_fn: crate::runtime::GetErrorClassFn, gotham_state: GothamState, @@ -45,10 +46,11 @@ impl Default for OpState { // pub(crate) fn new() -> OpState fn default() -> OpState { OpState { - resource_table: crate::ResourceTable::default(), + resource_table: Default::default(), + resource_table_2: Default::default(), op_table: OpTable::default(), get_error_class_fn: &|_| "Error", - gotham_state: GothamState::default(), + gotham_state: Default::default(), } } } |