diff options
| author | Yong He <yonghe@outlook.com> | 2025-07-14 18:51:57 -0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-07-15 01:51:57 +0000 |
| commit | 37143802781d8d480361d7c23202347ae3acf094 (patch) | |
| tree | 300a6f60f2ddd3a0d7f14ab07665dfff5d67f31c /tests/bugs | |
| parent | db06fbb163877b8823507b162ee7f2dfca8520f0 (diff) | |
Fix language server crash. (#7756)
* Fix language server crash.
* Fix tests.
* Fix.
* Revert changes.
Diffstat (limited to 'tests/bugs')
| -rw-r--r-- | tests/bugs/generic-type-arg-overloaded.slang | 3 | ||||
| -rw-r--r-- | tests/bugs/generic-type-arg-overloaded.slang.expected | 23 |
2 files changed, 2 insertions, 24 deletions
diff --git a/tests/bugs/generic-type-arg-overloaded.slang b/tests/bugs/generic-type-arg-overloaded.slang index 99150d2f0..d21ba0732 100644 --- a/tests/bugs/generic-type-arg-overloaded.slang +++ b/tests/bugs/generic-type-arg-overloaded.slang @@ -1,6 +1,6 @@ // generic-type-arg-overloaded.slang -//DIAGNOSTIC_TEST:SIMPLE: +//DIAGNOSTIC_TEST:SIMPLE(filecheck=CHECK): // Regression test to confirm that type checker // doesn't crash when an overloaded identifier @@ -11,6 +11,7 @@ interface IThing { int getVal(); } struct Stuff : IThing { int getVal() { return 1; } } // Conflicting declaration: +//CHECK: ([[# @LINE+1]]): error 30200: struct Stuff {} int util<T : IThing>() { return 1; } diff --git a/tests/bugs/generic-type-arg-overloaded.slang.expected b/tests/bugs/generic-type-arg-overloaded.slang.expected deleted file mode 100644 index 1c41da717..000000000 --- a/tests/bugs/generic-type-arg-overloaded.slang.expected +++ /dev/null @@ -1,23 +0,0 @@ -result code = -1 -standard error = { -tests/bugs/generic-type-arg-overloaded.slang(14): error 30200: declaration of 'Stuff' conflicts with existing declaration -struct Stuff {} - ^~~~~ -tests/bugs/generic-type-arg-overloaded.slang(11): note: see previous declaration of 'Stuff' -struct Stuff : IThing { int getVal() { return 1; } } - ^~~~~ -tests/bugs/generic-type-arg-overloaded.slang(26): error 39999: ambiguous reference to 'Stuff' - return util<Stuff>() - ^~~~~ -tests/bugs/generic-type-arg-overloaded.slang(14): note 39999: candidate: struct Stuff -struct Stuff {} - ^~~~~ -tests/bugs/generic-type-arg-overloaded.slang(11): note 39999: candidate: struct Stuff -struct Stuff : IThing { int getVal() { return 1; } } - ^~~~~ -tests/bugs/generic-type-arg-overloaded.slang(32): error 39999: expected a generic when using '<...>' (found: '() -> int') - + nonGeneric<G>(); - ^~~~~~~~~~ -} -standard output = { -} |
