-
Notifications
You must be signed in to change notification settings - Fork 77
Open
Description
As the title suggests, there is a behaviour discrepancy between import KernelAbstractions
and using KernelAbstractions
in relation to the @Const
macro. The following minimum example demonstrates the issue.
import KernelAbstractions as KA
KA.@kernel function example(KA.@Const(x)) end
# OUTPUT:
# ERROR: LoadError: MethodError: no method matching var"@Const"(::LineNumberNode, ::Module, ::Symbol)
# The function `@Const` exists, but no method is defined for this combination of argument types.
using KernelAbstractions: @Const
KA.@kernel function example(@Const(x)) end
# OUTPUT:
# example (generic function with 4 methods)
A brief search indicates that the issue almost certainly originates from these lines which compare to the literal value Symbol("@Const")
.
Metadata
Metadata
Assignees
Labels
No labels