glsl: rename get_record_instance() -> get_struct_instance()
authorTimothy Arceri <tarceri@itsqueeze.com>
Tue, 5 Mar 2019 04:46:14 +0000 (15:46 +1100)
committerTimothy Arceri <tarceri@itsqueeze.com>
Wed, 6 Mar 2019 02:10:02 +0000 (13:10 +1100)
Replace done using:
find ./src -type f -exec sed -i -- \
's/get_record_instance(/get_struct_instance(/g' {} \;

Acked-by: Karol Herbst <kherbst@redhat.com>
Acked-by: Jason Ekstrand <jason@jlekstrand.net>
Acked-by: Kenneth Graunke <kenneth@whitecape.org>
src/compiler/glsl/ast_to_hir.cpp
src/compiler/glsl/tests/array_refcount_test.cpp
src/compiler/glsl_types.cpp
src/compiler/glsl_types.h
src/compiler/nir_types.cpp

index 68acf2666cc2830720f84f148d0b17ed439974a0..feea92258d30b69afd81cc4a0e0e4e91d22ceb1b 100644 (file)
@@ -7581,7 +7581,7 @@ ast_struct_specifier::hir(exec_list *instructions,
 
    validate_identifier(this->name, loc, state);
 
-   type = glsl_type::get_record_instance(fields, decl_count, this->name);
+   type = glsl_type::get_struct_instance(fields, decl_count, this->name);
 
    if (!type->is_anonymous() && !state->symbols->add_type(name, type)) {
       const glsl_type *match = state->symbols->get_type(name);
index 45c204dc2f8a8e38555845ba1548ab81bff1c6b0..edd9cf42a31239bbd8da50e0026ae17a8c48fc5d 100644 (file)
@@ -477,7 +477,7 @@ TEST_F(array_refcount_test, do_not_process_array_inside_structure)
    };
 
    const glsl_type *const record_of_array_3_of_int =
-      glsl_type::get_record_instance(fields, ARRAY_SIZE(fields), "S");
+      glsl_type::get_struct_instance(fields, ARRAY_SIZE(fields), "S");
 
    ir_variable *var_a = new(mem_ctx) ir_variable(glsl_type::int_type,
                                                  "a",
index 260b07b67fe34dbb66e51260d48bbef0845c5ba3..24f319dbde285c9294550ed4cc793cb9291e1621 100644 (file)
@@ -434,7 +434,7 @@ const glsl_type *glsl_type::get_bare_type() const
          bare_fields[i].name = this->fields.structure[i].name;
       }
       const glsl_type *bare_type =
-         get_record_instance(bare_fields, this->length, this->name);
+         get_struct_instance(bare_fields, this->length, this->name);
       delete[] bare_fields;
       return bare_type;
    }
@@ -1127,7 +1127,7 @@ glsl_type::record_key_hash(const void *a)
 
 
 const glsl_type *
-glsl_type::get_record_instance(const glsl_struct_field *fields,
+glsl_type::get_struct_instance(const glsl_struct_field *fields,
                                unsigned num_fields,
                                const char *name)
 {
@@ -2375,7 +2375,7 @@ decode_type_from_blob(struct blob_reader *blob)
          t = glsl_type::get_interface_instance(fields, num_fields, packing,
                                                row_major, name);
       } else {
-         t = glsl_type::get_record_instance(fields, num_fields, name);
+         t = glsl_type::get_struct_instance(fields, num_fields, name);
       }
 
       free(fields);
index 8f9a69556eb6f17c9f82c2bab4f39b522de2d152..2e858bf4cd791f78c9fe87015154165a918fd0fc 100644 (file)
@@ -312,7 +312,7 @@ public:
    /**
     * Get the instance of a record type
     */
-   static const glsl_type *get_record_instance(const glsl_struct_field *fields,
+   static const glsl_type *get_struct_instance(const glsl_struct_field *fields,
                                               unsigned num_fields,
                                               const char *name);
 
index 32b47f2b60f1ace2f236237332e24a72c158a7ba..5e51dbc2d90a16f3f2bf36452ebeedc97a7d73a9 100644 (file)
@@ -486,7 +486,7 @@ const glsl_type *
 glsl_struct_type(const glsl_struct_field *fields,
                  unsigned num_fields, const char *name)
 {
-   return glsl_type::get_record_instance(fields, num_fields, name);
+   return glsl_type::get_struct_instance(fields, num_fields, name);
 }
 
 const glsl_type *