Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 1e76207c4357149a69994b53bb756f31996c13df
      
https://github.com/WebKit/WebKit/commit/1e76207c4357149a69994b53bb756f31996c13df
  Author: Tadeu Zagallo <[email protected]>
  Date:   2023-01-30 (Mon, 30 Jan 2023)

  Changed paths:
    M Source/WebGPU/WGSL/AST/AST.h
    M Source/WebGPU/WGSL/AST/ASTForward.h
    M Source/WebGPU/WGSL/AST/ASTIdentifierExpression.h
    A Source/WebGPU/WGSL/AST/ASTIdentityExpression.h
    M Source/WebGPU/WGSL/AST/ASTNode.h
    M Source/WebGPU/WGSL/AST/ASTVisitor.cpp
    M Source/WebGPU/WGSL/AST/ASTVisitor.h
    M Source/WebGPU/WGSL/GlobalVariableRewriter.cpp
    M Source/WebGPU/WebGPU.xcodeproj/project.pbxproj

  Log Message:
  -----------
  [WGSL] Add IdentityExpression node
https://bugs.webkit.org/show_bug.cgi?id=251262
<rdar://problem/104740808>

Reviewed by Myles C. Maxfield.

Address the FIXME from IdentifierExpression by introducing an 
IdentityExpression node.
This new node is a special node that does nothing but point to another 
expression. It's
useful when replacing nodes, if the new node is larger than the existing node. 
In which
case, an identity node can be used to point to the larger node.

* Source/WebGPU/WGSL/AST/AST.h:
* Source/WebGPU/WGSL/AST/ASTForward.h:
* Source/WebGPU/WGSL/AST/ASTIdentifierExpression.h:
* Source/WebGPU/WGSL/AST/ASTIdentityExpression.h: Copied from 
Source/WebGPU/WGSL/AST/ASTIdentifierExpression.h.
* Source/WebGPU/WGSL/AST/ASTNode.h:
* Source/WebGPU/WGSL/AST/ASTVisitor.cpp:
(WGSL::AST::Visitor::visit):
* Source/WebGPU/WGSL/AST/ASTVisitor.h:
* Source/WebGPU/WGSL/GlobalVariableRewriter.cpp:
(WGSL::replace):
(WGSL::RewriteGlobalVariables::visit):
* Source/WebGPU/WebGPU.xcodeproj/project.pbxproj:

Canonical link: https://commits.webkit.org/259552@main


_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to