- cross-posted to:
- programminghumor@lemmy.world
- programmerhumor@lemmy.ml
- cross-posted to:
- programminghumor@lemmy.world
- programmerhumor@lemmy.ml
Made with KolourPaint and screenshots from Kate (with the GitHub theme).
Made with KolourPaint and screenshots from Kate (with the GitHub theme).
At least be fair and cut out the
.into()
And bow to the compiler’s whims? I think not!
This shouldn’t compile, because .into needs the type from the left side and let needs the type from the right side.
If type constraints later in the function let the compiler infer the type, this syntax totally works.
Like if the variable is then used in a function that only takes one type? Huh.