Commit e8ded39
committed
[clang] fix nondeduced mismatch with nullptr template arguments
In deduction, when comparing template arguments of value kind,
we should check if the value matches. Values of different types can
still match. For example, `short(0)` matches `int(0)`.
Values of nullptr kind always match each other, since there is only
one such possible value. Similarly to integrals, the type does not
matter.1 parent 7b4befe commit e8ded39
File tree
3 files changed
+5
-7
lines changed- clang
- docs
- lib/Sema
- test/SemaTemplate
3 files changed
+5
-7
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
996 | 996 | | |
997 | 997 | | |
998 | 998 | | |
| 999 | + | |
999 | 1000 | | |
1000 | 1001 | | |
1001 | 1002 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2541 | 2541 | | |
2542 | 2542 | | |
2543 | 2543 | | |
2544 | | - | |
2545 | | - | |
| 2544 | + | |
| 2545 | + | |
2546 | 2546 | | |
2547 | | - | |
2548 | 2547 | | |
2549 | 2548 | | |
2550 | 2549 | | |
| |||
2559 | 2558 | | |
2560 | 2559 | | |
2561 | 2560 | | |
| 2561 | + | |
| 2562 | + | |
2562 | 2563 | | |
2563 | 2564 | | |
2564 | 2565 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
697 | 697 | | |
698 | 698 | | |
699 | 699 | | |
700 | | - | |
701 | 700 | | |
702 | 701 | | |
703 | 702 | | |
704 | | - | |
705 | 703 | | |
706 | | - | |
707 | 704 | | |
708 | 705 | | |
709 | | - | |
710 | 706 | | |
711 | 707 | | |
0 commit comments