Skip to content

Commit

Permalink
document partial generics breaking changes (#24055)
Browse files Browse the repository at this point in the history
refs #24010, split from #24051
  • Loading branch information
metagn authored Sep 4, 2024
1 parent f69809b commit c314155
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,19 @@
errors for ambiguous type symbols, and macros operating on generic proc AST
may encounter symchoice nodes instead of the arbitrarily resolved type symbol nodes.

- Partial generic instantiation of routines is no longer allowed. Previously
it compiled in niche situations due to bugs in the compiler.

```nim
proc foo[T, U](x: T, y: U) = echo (x, y)
proc foo[T, U](x: var T, y: U) = echo "var ", (x, y)
proc bar[T]() =
foo[float](1, "abc")
bar[int]() # before: (1.0, "abc"), now: type mismatch, missing generic parameter
```

## Standard library additions and changes

[//]: # "Changes:"
Expand Down

0 comments on commit c314155

Please sign in to comment.