]> Nishi Git Mirror - gwion.git/commitdiff
:art: rename @scan to class
authorfennecdjay <fennecdjay@gmail.com>
Fri, 28 Oct 2022 04:30:49 +0000 (06:30 +0200)
committerfennecdjay <fennecdjay@gmail.com>
Fri, 28 Oct 2022 04:30:49 +0000 (06:30 +0200)
src/env/type.c
src/lib/array.c
src/lib/closure.c
src/lib/dict.c
src/lib/object_op.c
src/lib/ptr.c
src/lib/ref.c
src/parse/template.c

index 05b38149a3ca7296df3706296ac3512cd91fdc30..fd1d8922263872fb0656f509da38970b806d7960 100644 (file)
@@ -98,7 +98,7 @@ ANN Type array_type(const Env env, const Type src, const m_uint depth) {
   const size_t tdepth     = depth + src->array_depth;
   const Type   base       = tdepth > 1 ? array_type(env, src, tdepth - 1) : src;
   struct TemplateScan ts  = {.t = base, /*.td=td*/ };
-  struct Op_Import    opi = {.op   = insert_symbol("@scan"),
+  struct Op_Import    opi = {.op   = insert_symbol("class"),
                           .lhs  = env->gwion->type[et_array],
                           .data = (uintptr_t)&ts};
   return op_check(env, &opi);
index 7276fa77e9ca84c9c435885545a55e006ed34e67..cf8d5e7391f0adc03e93550f1c5095c06ea27e01 100644 (file)
@@ -990,7 +990,7 @@ GWION_IMPORT(array) {
   GWI_BB(gwi_oper_end(gwi, "@each_idx", NULL))
   GWI_BB(gwi_oper_ini(gwi, "Array", NULL, NULL))
   GWI_BB(gwi_oper_add(gwi, opck_array_scan))
-  GWI_BB(gwi_oper_end(gwi, "@scan", NULL))
+  GWI_BB(gwi_oper_end(gwi, "class", NULL))
 
   GWI_BB(gwi_oper_ini(gwi, (m_str)OP_ANY_TYPE, NULL, "bool"))
   GWI_BB(gwi_oper_end(gwi, "@array_init", NoOp))
index 842f313968b73788b52a44b3a061f114bbe45bdf..312e371d8434169fafa6e9847686acc12136f648 100644 (file)
@@ -722,7 +722,7 @@ GWION_IMPORT(func) {
 
   GWI_BB(gwi_oper_ini(gwi, "funptr", NULL, NULL))
   GWI_BB(gwi_oper_add(gwi, opck_closure_scan))
-  GWI_BB(gwi_oper_end(gwi, "@scan", NULL))
+  GWI_BB(gwi_oper_end(gwi, "class", NULL))
 
   GWI_BB(gwi_oper_ini(gwi, (m_str)OP_ANY_TYPE, "function", NULL))
   GWI_BB(gwi_oper_add(gwi, opck_func_call))
index b242a1d380257cfc46345e98f03785ec4d3ea4b5..fd332ca1787cfda7a5ac3f787b3e0c9aa79da855 100644 (file)
@@ -691,7 +691,7 @@ GWION_IMPORT(dict) {
 
   GWI_BB(gwi_oper_ini(gwi, "Dict", NULL, NULL))
   GWI_BB(gwi_oper_add(gwi, opck_dict_scan))
-  GWI_BB(gwi_oper_end(gwi, "@scan", NULL))
+  GWI_BB(gwi_oper_end(gwi, "class", NULL))
 
   GWI_BB(gwi_oper_ini(gwi, "Dict", NULL, "int"))
   GWI_BB(gwi_oper_emi(gwi, opem_dict_each))
index ad031595b0bda94516f976cdeab4666f474dff2b..4aa44c55c7dbdb25195a4b764346f40f9892f281 100644 (file)
@@ -437,6 +437,6 @@ GWION_IMPORT(object_op) {
   GWI_BB(gwi_oper_end(gwi, "!", NULL))
   GWI_BB(gwi_oper_ini(gwi, "@Compound", NULL, NULL))
   GWI_BB(gwi_oper_add(gwi, opck_struct_scan))
-  GWI_BB(gwi_oper_end(gwi, "@scan", NULL))
+  GWI_BB(gwi_oper_end(gwi, "class", NULL))
   return GW_OK;
 }
index f623dd7d227ed356b4862b1582496fd06b42c2c4..1274b3bfc25974dd86daaa821589a806edb5f1d4 100644 (file)
@@ -185,7 +185,7 @@ GWION_IMPORT(ptr) {
   GWI_BB(gwi_class_end(gwi))
   GWI_BB(gwi_oper_ini(gwi, "Ptr", NULL, NULL))
   GWI_BB(gwi_oper_add(gwi, opck_ptr_scan))
-  GWI_BB(gwi_oper_end(gwi, "@scan", NULL))
+  GWI_BB(gwi_oper_end(gwi, "class", NULL))
   GWI_BB(gwi_oper_ini(gwi, (m_str)OP_ANY_TYPE, "Ptr", NULL))
   GWI_BB(gwi_oper_add(gwi, opck_ptr_assign))
   GWI_BB(gwi_oper_emi(gwi, opem_ptr_assign))
index bbc19bb80e22530c65e7b5cd5c8f5732aa4d23da..6f75b68d19374ee9bd5efd92ec83e1af52992741 100644 (file)
@@ -192,6 +192,6 @@ GWION_IMPORT(ref) {
   gwidoc(gwi, "internal `Ref` type creation.");
   GWI_BB(gwi_oper_ini(gwi, "Ref", NULL, NULL))
   GWI_BB(gwi_oper_add(gwi, opck_ref_scan))
-  GWI_BB(gwi_oper_end(gwi, "@scan", NULL))
+  GWI_BB(gwi_oper_end(gwi, "class", NULL))
   return GW_OK;
 }
index 5936114a2c346f7ad28cd6859f0f93c5eb2f29e4..2684fac67caca869de977bf4580cfc8d41ec2a75 100644 (file)
@@ -182,7 +182,7 @@ ANN static Type _scan_type(const Env env, const Type t, Type_Decl *td) {
         ? t->info->cdef->base.tmpl->list : NULL;
     const bool is_spread = is_spread_tmpl(t->info->cdef->base.tmpl);
     if(!single_variadic) CHECK_BO(check_tmpl(env, tl, sl, td->pos, is_spread));
-    struct Op_Import opi = {.op   = insert_symbol("@scan"),
+    struct Op_Import opi = {.op   = insert_symbol("class"),
                             .lhs  = t,
                             .data = (uintptr_t)&ts,
                             .pos  = td->pos};