mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
[Diagnostics] Improve diagnostics for generic types with unfulfilled requirements
This commit is contained in:
@@ -102,6 +102,19 @@ public:
|
||||
/// array of the generic parameters for the innermost generic type.
|
||||
ArrayRef<GenericTypeParamType *> getInnermostGenericParams() const;
|
||||
|
||||
/// Create a text string that describes the bindings of generic parameters
|
||||
/// that are relevant to the given set of types, e.g.,
|
||||
/// "[with T = Bar, U = Wibble]".
|
||||
///
|
||||
/// \param types The types that will be scanned for generic type parameters,
|
||||
/// which will be used in the resulting type.
|
||||
///
|
||||
/// \param substitutions The generic parameter -> generic argument
|
||||
/// substitutions that will have been applied to these types.
|
||||
/// These are used to produce the "parameter = argument" bindings in the test.
|
||||
std::string gatherGenericParamBindingsText(
|
||||
ArrayRef<Type> types, const TypeSubstitutionMap &substitutions) const;
|
||||
|
||||
/// Retrieve the requirements.
|
||||
ArrayRef<Requirement> getRequirements() const {
|
||||
return const_cast<GenericSignature *>(this)->getRequirementsBuffer();
|
||||
|
||||
Reference in New Issue
Block a user