[webkit-changes] [WebKit/WebKit] e511c2: [WGSL] Add support for calls with simple built-in ...

Tadeu Zagallo noreply at github.com
Mon May 22 00:13:23 PDT 2023


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: e511c232f3f7a97c1ee7f4c8a0b50d4eb0f03e1a
      https://github.com/WebKit/WebKit/commit/e511c232f3f7a97c1ee7f4c8a0b50d4eb0f03e1a
  Author: Tadeu Zagallo <tzagallo at apple.com>
  Date:   2023-05-22 (Mon, 22 May 2023)

  Changed paths:
    M Source/WebGPU/WGSL/Metal/MetalFunctionWriter.cpp
    M Source/WebGPU/WGSL/Parser.cpp

  Log Message:
  -----------
  [WGSL] Add support for calls with simple built-in types
https://bugs.webkit.org/show_bug.cgi?id=257028
rdar://109564906

Reviewed by Myles C. Maxfield.

Allow function calls with simple built-in types (i.e. function-style cast) such
as `f32(x)`. The way we currently handle it is not great, since we treat type
names as keywords in the lexer, but all of this will have to be refactored soon
when we update the parser to solve the template ambiguity. For now, this unblocks
a few more CTS tests to pass.

* Source/WebGPU/WGSL/Metal/MetalFunctionWriter.cpp:
(WGSL::Metal::FunctionDefinitionWriter::visit):
* Source/WebGPU/WGSL/Parser.cpp:
(WGSL::Parser<Lexer>::parsePrimaryExpression):

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




More information about the webkit-changes mailing list