mirror of
https://github.com/encounter/dawn-cmake.git
synced 2025-12-21 02:39:11 +00:00
Rename type Base methods
This CL renames StructBase and StructMemberBase to drop the Base suffix now that the move is complete. Bug: tint:1718 Change-Id: If8126e4993c58bb2de475c2b18695705082a0a92 Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/113800 Reviewed-by: Ben Clayton <bclayton@google.com> Kokoro: Kokoro <noreply+kokoro@google.com> Commit-Queue: Dan Sinclair <dsinclair@chromium.org>
This commit is contained in:
committed by
Dawn LUCI CQ
parent
ac146b1a48
commit
28a7827981
@@ -416,7 +416,7 @@ struct Composite : ImplConstant {
|
||||
utils::Vector<const sem::Constant*, 4> conv_els;
|
||||
conv_els.Reserve(elements.Length());
|
||||
std::function<const type::Type*(size_t idx)> target_el_ty;
|
||||
if (auto* str = target_ty->As<type::StructBase>()) {
|
||||
if (auto* str = target_ty->As<type::Struct>()) {
|
||||
if (str->Members().Length() != elements.Length()) {
|
||||
TINT_ICE(Resolver, builder.Diagnostics())
|
||||
<< "const-eval conversion of structure has mismatched element counts";
|
||||
@@ -494,7 +494,7 @@ const ImplConstant* ZeroValue(ProgramBuilder& builder, const type::Type* type) {
|
||||
}
|
||||
return nullptr;
|
||||
},
|
||||
[&](const type::StructBase* s) -> const ImplConstant* {
|
||||
[&](const type::Struct* s) -> const ImplConstant* {
|
||||
utils::Hashmap<const type::Type*, const ImplConstant*, 8> zero_by_type;
|
||||
utils::Vector<const sem::Constant*, 4> zeros;
|
||||
zeros.Reserve(s->Members().Length());
|
||||
@@ -1449,7 +1449,7 @@ ConstEval::Result ConstEval::Index(const sem::Expression* obj_expr,
|
||||
}
|
||||
|
||||
ConstEval::Result ConstEval::MemberAccess(const sem::Expression* obj_expr,
|
||||
const type::StructMemberBase* member) {
|
||||
const type::StructMember* member) {
|
||||
auto obj_val = obj_expr->ConstantValue();
|
||||
if (!obj_val) {
|
||||
return nullptr;
|
||||
|
||||
@@ -35,7 +35,7 @@ class Constant;
|
||||
class Expression;
|
||||
} // namespace tint::sem
|
||||
namespace tint::type {
|
||||
class StructMemberBase;
|
||||
class StructMember;
|
||||
} // namespace tint::type
|
||||
|
||||
namespace tint::resolver {
|
||||
@@ -94,7 +94,7 @@ class ConstEval {
|
||||
/// @param obj the object being accessed
|
||||
/// @param member the member
|
||||
/// @return the result of the member access, or null if the value cannot be calculated
|
||||
Result MemberAccess(const sem::Expression* obj, const type::StructMemberBase* member);
|
||||
Result MemberAccess(const sem::Expression* obj, const type::StructMember* member);
|
||||
|
||||
/// @param ty the result type
|
||||
/// @param vector the vector being swizzled
|
||||
|
||||
Reference in New Issue
Block a user