mirror of
https://github.com/encounter/dawn-cmake.git
synced 2025-12-20 10:25:28 +00:00
Add ability to generate typedefs from dawn.json
Can be used to help with deprecation during simple struct renames. Includes typedefs for VertexAttributeDescriptor -> VertexAttribute and VertexBufferLayoutDescriptor -> VertexBufferLayout as specified by the latest RenderPipelineDescriptor changes. Bug: dawn:642 Change-Id: Iab3d74d179884499540e813b0e66859713031ccb Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/40581 Commit-Queue: Brandon Jones <bajones@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org>
This commit is contained in:
committed by
Commit Bot service account
parent
734e88b2e7
commit
58a471ae25
@@ -63,6 +63,13 @@ namespace wgpu {
|
||||
struct {{as_cppType(type.name)}};
|
||||
{% endfor %}
|
||||
|
||||
{% for typeDef in by_category["typedef"] %}
|
||||
// {{as_cppType(typeDef.name)}} is deprecated.
|
||||
// Use {{as_cppType(typeDef.type.name)}} instead.
|
||||
using {{as_cppType(typeDef.name)}} = {{as_cppType(typeDef.type.name)}};
|
||||
|
||||
{% endfor %}
|
||||
|
||||
template<typename Derived, typename CType>
|
||||
class ObjectBase {
|
||||
public:
|
||||
|
||||
Reference in New Issue
Block a user