Files
swift-mirror/validation-test/compiler_crashers_2_fixed/2819a60354d8389.swift
Slava Pestov 5cdc9a6570 AST: More robust TypeBase::getSuperclassForDecl()
This can return ErrorType if the AST is invalid.

A handful of callers handle the ErrorType result, but most don't,
blindly assuming the result is always a nominal type. This resulted
in a crash in at least one test case.

Lift the burden from callers by always returning a nominal type here.
2025-06-10 16:49:57 -04:00

4 lines
244 B
Swift

// {"signature":"swift::rewriting::PropertyMap::addSuperclassProperty(swift::rewriting::Term, swift::rewriting::Symbol, unsigned int)"}
// RUN: not %target-swift-frontend -typecheck %s
class a < b class c : a func d < b where b : a<Int>, b : c