File tree Expand file tree Collapse file tree 2 files changed +6
-9
lines changed
crates/environ/src/component Expand file tree Collapse file tree 2 files changed +6
-9
lines changed Original file line number Diff line number Diff line change @@ -925,7 +925,7 @@ impl<'a> Inliner<'a> {
925925 frame. funcs . push ( dfg:: CoreDef :: Trampoline ( index) ) ;
926926 }
927927 ErrorContextNew { func, options } => {
928- let ty = types. error_context_type ( ) ?;
928+ let ty = types. error_context_table_type ( ) ?;
929929 let options = self . adapter_options ( frame, types, options) ;
930930 let options = self . canonical_options ( options) ;
931931 let index = self
@@ -935,7 +935,7 @@ impl<'a> Inliner<'a> {
935935 frame. funcs . push ( dfg:: CoreDef :: Trampoline ( index) ) ;
936936 }
937937 ErrorContextDebugMessage { func, options } => {
938- let ty = types. error_context_type ( ) ?;
938+ let ty = types. error_context_table_type ( ) ?;
939939 let options = self . adapter_options ( frame, types, options) ;
940940 let options = self . canonical_options ( options) ;
941941 let index = self . result . trampolines . push ( (
@@ -945,7 +945,7 @@ impl<'a> Inliner<'a> {
945945 frame. funcs . push ( dfg:: CoreDef :: Trampoline ( index) ) ;
946946 }
947947 ErrorContextDrop { func } => {
948- let ty = types. error_context_type ( ) ?;
948+ let ty = types. error_context_table_type ( ) ?;
949949 let index = self
950950 . result
951951 . trampolines
Original file line number Diff line number Diff line change @@ -443,11 +443,6 @@ impl ComponentTypesBuilder {
443443 Ok ( ret)
444444 }
445445
446- /// Retrieve Wasmtime's type representation of the `error-context` type.
447- pub fn error_context_type ( & mut self ) -> Result < TypeComponentLocalErrorContextTableIndex > {
448- self . error_context_table_type ( )
449- }
450-
451446 fn valtype ( & mut self , types : TypesRef < ' _ > , ty : & ComponentValType ) -> Result < InterfaceType > {
452447 assert_eq ! ( types. id( ) , self . module_types. validator_id( ) ) ;
453448 match ty {
@@ -599,7 +594,9 @@ impl ComponentTypesBuilder {
599594 } ) )
600595 }
601596
602- fn error_context_table_type ( & mut self ) -> Result < TypeComponentLocalErrorContextTableIndex > {
597+ /// Retrieve Wasmtime's type representation of the `error-context` type from
598+ /// the point of view of the current component instance.
599+ pub fn error_context_table_type ( & mut self ) -> Result < TypeComponentLocalErrorContextTableIndex > {
603600 Ok ( self . add_error_context_table_type ( TypeErrorContextTable {
604601 instance : self . resources . get_current_instance ( ) . unwrap ( ) ,
605602 } ) )
You can’t perform that action at this time.
0 commit comments