Skip to content

Commit c337446

Browse files
authored
Merge pull request #85537 from hamishknight/fuzzy
[test] Add some more known crashers
2 parents b4d2f8a + 86f8e22 commit c337446

23 files changed

+54
-25
lines changed
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
// {"kind":"complete","original":"00fc7609","signature":"(anonymous namespace)::CodeCompletionCallbacksImpl::typecheckParsedType()","signatureAssert":"Assertion failed: (!type->hasTypeParameter() && \"no generic environment provided for type with type parameters\"), function mapTypeIntoEnvironment"}
2+
// RUN: not --crash %target-swift-ide-test -code-completion -batch-code-completion -skip-filecheck -code-completion-diagnostics -source-filename %s
3+
protocol a:Self#^^#
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
// {"kind":"complete","original":"0435fa64","signature":"swift::ide::CompletionLookup::foundDecl(swift::ValueDecl*, swift::DeclVisibilityKind, swift::DynamicLookupInfo)","signatureAssert":"Assertion failed: (!type->hasTypeParameter() && \"no generic environment provided for type with type parameters\"), function mapTypeIntoEnvironment"}
2+
// RUN: not --crash %target-swift-ide-test -code-completion -batch-code-completion -skip-filecheck -code-completion-diagnostics -source-filename %s
3+
extension Sequence where a == <#type#>[ {
4+
#^^#
5+
}
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// {"kind":"complete","original":"0116e8cd","signature":"swift::ConformanceChecker::resolveWitnessViaLookup(swift::ValueDecl*)","signatureAssert":"Assertion failed: (Conformance->getWitnessUncached(requirement).getDecl() == match.Witness && \"Deduced different witnesses?\"), function recordWitness"}
1+
// {"kind":"complete","original":"0116e8cd","signature":"swift::ConformanceChecker::recordWitness(swift::ValueDecl*, swift::RequirementMatch const&)","signatureAssert":"Assertion failed: (Conformance->getWitnessUncached(requirement).getDecl() == match.Witness && \"Deduced different witnesses?\"), function recordWitness"}
22
// RUN: not --crash %target-swift-ide-test -code-completion -batch-code-completion -skip-filecheck -code-completion-diagnostics -source-filename %s
33
struct a: OptionSet {
44
static rawValue = a init(rawValue: Int ) {
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
// {"kind":"complete","original":"bcb7c8c1","signature":"(anonymous namespace)::ConstraintGenerator::visitTapExpr(swift::TapExpr*)","signatureAssert":"Assertion failed: ((varDC == CS.DC || isa<AbstractClosureExpr>(varDC) || varDC->isChildContextOf(CS.DC)) && \"TapExpr var should be in the same DeclContext we're checking it in!\"), function visitTapExpr"}
2+
// RUN: not --crash %target-swift-ide-test -code-completion -batch-code-completion -skip-filecheck -code-completion-diagnostics -source-filename %s
3+
func a -> @b("\()." #^^#

validation-test/IDE/crashers/DeclContext-getDeclaredInterfaceType-dffa2c.swift renamed to validation-test/IDE/crashers/DeclContext-getDeclaredTypeInContext-dffa2c.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// {"kind":"complete","original":"7f4bcc9e","signature":"swift::DeclContext::getDeclaredInterfaceType() const","signatureAssert":"Assertion failed: (detail::isPresent(Val) && \"dyn_cast on a non-existent value\"), function dyn_cast"}
1+
// {"kind":"complete","original":"7f4bcc9e","signature":"swift::DeclContext::getDeclaredTypeInContext() const"}
22
// RUN: not --crash %target-swift-ide-test -code-completion -batch-code-completion -skip-filecheck -code-completion-diagnostics -source-filename %s
33
extension Sequence where a == b[ {
44
func c() -> #^^#
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
// {"kind":"complete","original":"e6459edc","signature":"swift::TypeChecker::typeCheckCondition(swift::Expr*&, swift::DeclContext*)","signatureAssert":"Assertion failed: (!expr->getType() && \"the bool condition is already type checked\"), function typeCheckCondition"}
2+
// RUN: not --crash %target-swift-ide-test -code-completion -batch-code-completion -skip-filecheck -code-completion-diagnostics -source-filename %s
3+
(if) {}#^^#

validation-test/IDE/crashers/TypeChecker-typeCheckStmtConditionElement-974abc.swift

Lines changed: 0 additions & 3 deletions
This file was deleted.
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
// {"kind":"complete","original":"d73870ca","signature":"swift::TypeResolution::resolveContextualType(swift::TypeRepr*, swift::DeclContext*, swift::GenericSignature, swift::TypeResolutionOptions, llvm::function_ref<swift::Type (swift::UnboundGenericType*)>, llvm::function_ref<swift::Type (swift::ASTContext&, swift::PlaceholderTypeRepr*)>, llvm::function_ref<swift::Type (swift::Type, swift::PackElementTypeRepr*)>, llvm::function_ref<void (swift::GenericTypeDecl*, llvm::function_ref<swift::Type (swift::SubstitutableType*)>)>, swift::SILTypeResolutionContext*)","signatureAssert":"Assertion failed: (!type->hasTypeParameter() && \"no generic environment provided for type with type parameters\"), function mapTypeIntoEnvironment"}
2+
// RUN: not --crash %target-swift-ide-test -code-completion -batch-code-completion -skip-filecheck -code-completion-diagnostics -source-filename %s
3+
@ a(b
4+
#^^# struct c<b
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// {"kind":"typecheck","original":"cb3e622a","signature":"swift::ast_scope::ASTScopeImpl::checkSourceRangeBeforeAddingChild(swift::ast_scope::ASTScopeImpl*, swift::ASTContext const&) const"}
1+
// {"kind":"typecheck","original":"cb3e622a","signature":"swift::ast_scope::ASTScopeImpl::addChild(swift::ast_scope::ASTScopeImpl*, swift::ASTContext&)"}
22
// RUN: not --crash %target-swift-frontend -typecheck %s
33
{
44
let a,

validation-test/compiler_crashers/AbstractStorageDecl-mutability-98fb6d.swift

Lines changed: 0 additions & 4 deletions
This file was deleted.

0 commit comments

Comments
 (0)