@@ -3241,6 +3241,10 @@ class ValueDecl : public Decl {
32413241 // / Get the decl for this value's opaque result type, if it has one.
32423242 OpaqueTypeDecl *getOpaqueResultTypeDecl () const ;
32433243
3244+ // / Gets the decl for this value's opaque result type if it has already been
3245+ // / computed, or `nullopt` otherwise. This should only be used for dumping.
3246+ std::optional<OpaqueTypeDecl *> getCachedOpaqueResultTypeDecl () const ;
3247+
32443248 // / Get the representative for this value's opaque result type, if it has one.
32453249 // / Returns a `TypeRepr` instead of an `OpaqueReturnTypeRepr` because 'some'
32463250 // / types might appear in one or more structural positions, e.g. (some P,
@@ -7657,6 +7661,10 @@ class AbstractFunctionDecl : public GenericContext, public ValueDecl {
76577661 // / Retrieves the thrown interface type.
76587662 Type getThrownInterfaceType () const ;
76597663
7664+ // / Returns the thrown interface type of this function if it has already been
7665+ // / computed, otherwise `nullopt`. This should only be used for dumping.
7666+ std::optional<Type> getCachedThrownInterfaceType () const ;
7667+
76607668 // / Retrieve the "effective" thrown interface type, or std::nullopt if
76617669 // / this function cannot throw.
76627670 // /
@@ -8217,6 +8225,10 @@ class FuncDecl : public AbstractFunctionDecl {
82178225 // / Retrieve the result interface type of this function.
82188226 Type getResultInterfaceType () const ;
82198227
8228+ // / Returns the result interface type of this function if it has already been
8229+ // / computed, otherwise `nullopt`. This should only be used for dumping.
8230+ std::optional<Type> getCachedResultInterfaceType () const ;
8231+
82208232 // / isUnaryOperator - Determine whether this is a unary operator
82218233 // / implementation. This check is a syntactic rather than type-based check,
82228234 // / which looks at the number of parameters specified, in order to allow
@@ -9417,6 +9429,10 @@ class MacroDecl : public GenericContext, public ValueDecl {
94179429 // / Retrieve the interface type produced when expanding this macro.
94189430 Type getResultInterfaceType () const ;
94199431
9432+ // / Returns the result interface type of this macro if it has already been
9433+ // / computed, otherwise `nullopt`. This should only be used for dumping.
9434+ std::optional<Type> getCachedResultInterfaceType () const ;
9435+
94209436 // / Determine the contexts in which this macro can be applied.
94219437 MacroRoles getMacroRoles () const ;
94229438
0 commit comments