Commit 7814a44
committed
Typer: Refine position when catching top-level TypeError
Ensures stackoverflows aren't hidden by errors, without needing #4511.
Also add relevant testcase from
#4385 (comment); I confirmed
this fails without the position fix.1 parent 34c4107 commit 7814a44
File tree
2 files changed
+14
-1
lines changed- compiler/src/dotty/tools/dotc/typer
- tests/neg
2 files changed
+14
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1862 | 1862 | | |
1863 | 1863 | | |
1864 | 1864 | | |
1865 | | - | |
| 1865 | + | |
| 1866 | + | |
| 1867 | + | |
| 1868 | + | |
| 1869 | + | |
| 1870 | + | |
| 1871 | + | |
1866 | 1872 | | |
1867 | 1873 | | |
1868 | 1874 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
0 commit comments