JuliaLang / JuliaLang/JuliaSyntax.jl
Vector of functions error message
Open
error messages
lowering
- Dominant language
- Julia
- Stars
- 293
- Forks
- 50
- PR merge metrics
- No merged PRs in 30d
Description
```jl
a = Vector{Function}(undef, 5)
for i in 1:5
a[i](t) = cos(i*t)
end
ERROR: syntax: invalid function name "a[i]" around
```
https://discourse.julialang.org/t/vector-of-functions/94811
This error says what the problem is and where, but not how to solve it, which is to use an anonymous function `a[i] = t -> cos(i*t)`.
If there is tooling to help generate this kind of message that would be helpful.
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.