Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

+ function string concatenation hint should not apply to zero args #55745

Closed
StefanKarpinski opened this issue Sep 12, 2024 · 1 comment · Fixed by #55749
Closed

+ function string concatenation hint should not apply to zero args #55745

StefanKarpinski opened this issue Sep 12, 2024 · 1 comment · Fixed by #55749
Labels
domain:error messages Better, more actionable error messages good first issue Indicates a good issue for first-time contributors to Julia status:help wanted Indicates that a maintainer wants help on an issue or pull request

Comments

@StefanKarpinski
Copy link
Sponsor Member

julia> +()
ERROR: MethodError: no method matching +()
String concatenation is performed with * (See also: https://docs.julialang.org/en/v1/manual/strings/#man-concatenation).
@StefanKarpinski StefanKarpinski added the status:help wanted Indicates that a maintainer wants help on an issue or pull request label Sep 12, 2024
@KristofferC
Copy link
Sponsor Member

Should check that in

if (ex.f === +) && all(i -> i <: AbstractString, arg_types)

length(arg_types) > 0 (and also add a test)

@KristofferC KristofferC added the good first issue Indicates a good issue for first-time contributors to Julia label Sep 12, 2024
@nsajko nsajko added the domain:error messages Better, more actionable error messages label Sep 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
domain:error messages Better, more actionable error messages good first issue Indicates a good issue for first-time contributors to Julia status:help wanted Indicates that a maintainer wants help on an issue or pull request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants