tek / splain

better implicit errors for scala
MIT License
370 stars 29 forks source link

Add DiffDisambiguationFormatter #109

Closed tribbloid closed 9 months ago

tribbloid commented 9 months ago

The new formatter will add prefix context to type diff if it is not strong enough to show the difference. E.g. the following error:

newSource1.scala:6: error: type mismatch;
  Long|Long
        else add2(x.head, y.head) :: add(x.tail, y.tail)
                    ^

will become

newSource1.scala:6: error: type mismatch;
  Long {in <none>}|Long {in scala}
        else add2(x.head, y.head) :: add(x.tail, y.tail)
                    ^
github-actions[bot] commented 9 months ago

Test Report (2.13.9)

79 tests  +1   79 :heavy_check_mark: +1   14s :stopwatch: +2s 14 suites +1     0 :zzz: ±0  14 files   +1     0 :x: ±0 

Results for commit 2b4db31e. ± Comparison against base commit 3d6fe232.

github-actions[bot] commented 9 months ago

Test Report (2.13.10)

79 tests  +1   79 :heavy_check_mark: +1   13s :stopwatch: +2s 14 suites +1     0 :zzz: ±0  14 files   +1     0 :x: ±0 

Results for commit 2b4db31e. ± Comparison against base commit 3d6fe232.

github-actions[bot] commented 9 months ago

Test Report (2.13.11)

79 tests  +1   79 :heavy_check_mark: +1   12s :stopwatch: -1s 14 suites +1     0 :zzz: ±0  14 files   +1     0 :x: ±0 

Results for commit 2b4db31e. ± Comparison against base commit 3d6fe232.

github-actions[bot] commented 9 months ago

Test Report (2.13.12)

79 tests  +1   79 :heavy_check_mark: +1   12s :stopwatch: -2s 14 suites +1     0 :zzz: ±0  14 files   +1     0 :x: ±0 

Results for commit 2b4db31e. ± Comparison against base commit 3d6fe232.

tribbloid commented 9 months ago

turns out this is a bad idea, will have to scrape it in favour of a simpler design