Browse Source

* tai_wasmstruc_try_catch renamed tai_wasmstruc_legacy_try_catch

Nikolay Nikolov 1 day ago
parent
commit
6a934513ea
3 changed files with 14 additions and 14 deletions
  1. 2 2
      compiler/aggas.pas
  2. 11 11
      compiler/wasm32/aasmcpu.pas
  3. 1 1
      compiler/wasm32/cpupi.pas

+ 2 - 2
compiler/aggas.pas

@@ -1756,8 +1756,8 @@ implementation
                  begin
                    writer.AsmWriteLn('.err try {');
                    WriteTree(tai_wasmstruc_legacy_try(hp).try_asmlist);
-                   if hp is tai_wasmstruc_try_catch then
-                     with tai_wasmstruc_try_catch(hp) do
+                   if hp is tai_wasmstruc_legacy_try_catch then
+                     with tai_wasmstruc_legacy_try_catch(hp) do
                        begin
                          for i:=low(catch_list) to high(catch_list) do
                            begin

+ 11 - 11
compiler/wasm32/aasmcpu.pas

@@ -278,9 +278,9 @@ uses
         procedure ConvertToFlatList(l: TAsmList);override;
       end;
 
-      { tai_wasmstruc_try_catch }
+      { tai_wasmstruc_legacy_try_catch }
 
-      tai_wasmstruc_try_catch = class(tai_wasmstruc_legacy_try)
+      tai_wasmstruc_legacy_try_catch = class(tai_wasmstruc_legacy_try)
         catch_list: array of record
           catch_instr: taicpu;
           asmlist: TAsmList;
@@ -1575,7 +1575,7 @@ uses
         until Done;
         case taicpu(p).opcode of
           a_end_legacy_try,a_legacy_catch,a_legacy_catch_all:
-            result:=tai_wasmstruc_try_catch.internal_create(taicpu(p),tmp_asmlist,srclist);
+            result:=tai_wasmstruc_legacy_try_catch.internal_create(taicpu(p),tmp_asmlist,srclist);
           a_legacy_delegate:
             result:=tai_wasmstruc_legacy_try_delegate.internal_create(taicpu(p),tmp_asmlist,srclist);
           else
@@ -1614,9 +1614,9 @@ uses
         l.concatList(try_asmlist);
       end;
 
-    { tai_wasmstruc_try_catch }
+    { tai_wasmstruc_legacy_try_catch }
 
-    constructor tai_wasmstruc_try_catch.internal_create(first_ins: taicpu; a_try_asmlist, srclist: TAsmList);
+    constructor tai_wasmstruc_legacy_try_catch.internal_create(first_ins: taicpu; a_try_asmlist, srclist: TAsmList);
       var
         p: tai;
 
@@ -1694,7 +1694,7 @@ uses
         until Done;
       end;
 
-    destructor tai_wasmstruc_try_catch.Destroy;
+    destructor tai_wasmstruc_legacy_try_catch.Destroy;
       var
         i: Integer;
       begin
@@ -1707,12 +1707,12 @@ uses
         inherited Destroy;
       end;
 
-    function tai_wasmstruc_try_catch.getcopy: TLinkedListItem;
+    function tai_wasmstruc_legacy_try_catch.getcopy: TLinkedListItem;
       var
-        p: tai_wasmstruc_try_catch;
+        p: tai_wasmstruc_legacy_try_catch;
         i: Integer;
       begin
-        p:=tai_wasmstruc_try_catch(inherited getcopy);
+        p:=tai_wasmstruc_legacy_try_catch(inherited getcopy);
         p.catch_list:=Copy(catch_list);
         for i:=0 to length(catch_list)-1 do
           begin
@@ -1732,7 +1732,7 @@ uses
         getcopy:=p;
       end;
 
-    procedure tai_wasmstruc_try_catch.Map(f: TAsmMapFunc; blockstack: twasmstruc_stack);
+    procedure tai_wasmstruc_legacy_try_catch.Map(f: TAsmMapFunc; blockstack: twasmstruc_stack);
       var
         i: Integer;
       begin
@@ -1744,7 +1744,7 @@ uses
         blockstack.pop;
       end;
 
-    procedure tai_wasmstruc_try_catch.ConvertToFlatList(l: TAsmList);
+    procedure tai_wasmstruc_legacy_try_catch.ConvertToFlatList(l: TAsmList);
       var
         i: Integer;
       begin

+ 1 - 1
compiler/wasm32/cpupi.pas

@@ -953,7 +953,7 @@ implementation
                     internalerror(2023102201);
                   resolve_labels_of_asmlist_with_try_blocks_recursive(tai_wasmstruc_legacy_try(hp).try_asmlist);
                   if taicpu_wasm_structured_instruction(hp).wstyp=aitws_legacy_try_catch then
-                    with tai_wasmstruc_try_catch(hp) do
+                    with tai_wasmstruc_legacy_try_catch(hp) do
                       begin
                         for i:=low(catch_list) to high(catch_list) do
                           resolve_labels_of_asmlist_with_try_blocks_recursive(catch_list[i].asmlist);