Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 89a790ad2a426bfdcb8f91242716cab722a972dd
https://github.com/WebKit/WebKit/commit/89a790ad2a426bfdcb8f91242716cab722a972dd
Author: Tadeu Zagallo <[email protected]>
Date: 2023-06-01 (Thu, 01 Jun 2023)
Changed paths:
M Source/WebGPU/WGSL/ContextProvider.h
M Source/WebGPU/WGSL/ContextProviderInlines.h
M Source/WebGPU/WGSL/TypeCheck.cpp
A Source/WebGPU/WGSL/tests/invalid/function-call.wgsl
Log Message:
-----------
[WGSL] Type check user-defined function calls
https://bugs.webkit.org/show_bug.cgi?id=257557
rdar://110075508
Reviewed by Myles C. Maxfield.
Before resolving overloads, check if a user-defined function is available when
type checking function calls. The implementation is rather similar to how we
validate struct initializers, but trying to share the code made the code more
confusing than concise, so for now the two paths are kept separately.
* Source/WebGPU/WGSL/ContextProvider.h:
* Source/WebGPU/WGSL/ContextProviderInlines.h:
(WGSL::ContextProvider<Value>::Context::lookup const):
(WGSL::ContextProvider<Value>::Context::add):
(WGSL::ContextProvider<Value>::introduceVariable const):
(WGSL::ContextProvider<Value>::readVariable const const):
* Source/WebGPU/WGSL/TypeCheck.cpp:
(WGSL::TypeChecker::visit):
* Source/WebGPU/WGSL/tests/invalid/function-call.wgsl: Added.
Canonical link: https://commits.webkit.org/264784@main
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes