mirror of
https://github.com/encounter/dawn-cmake.git
synced 2025-12-09 05:27:49 +00:00
transforms: Add a ProgramBuilder::Sym() helper
This creates a new, unnamed symbol. Change-Id: I0ea11e812296c3215ba624a18777d3e7233e2ae4 Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/49441 Kokoro: Kokoro <noreply+kokoro@google.com> Reviewed-by: Ben Clayton <bclayton@google.com> Commit-Queue: Ben Clayton <bclayton@google.com> Auto-Submit: James Price <jrprice@google.com>
This commit is contained in:
committed by
Commit Bot service account
parent
77f7f5d369
commit
65ae64d009
@@ -878,6 +878,9 @@ class ProgramBuilder {
|
||||
// AST helper methods
|
||||
//////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
/// @return a new unnamed symbol
|
||||
Symbol Sym() { return Symbols().New(); }
|
||||
|
||||
/// @param name the symbol string
|
||||
/// @return a Symbol with the given name
|
||||
Symbol Sym(const std::string& name) { return Symbols().Register(name); }
|
||||
|
||||
Reference in New Issue
Block a user