We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 237c4c4 commit b8c007fCopy full SHA for b8c007f
clang/lib/AST/Decl.cpp
@@ -3745,7 +3745,13 @@ bool FunctionDecl::doesDeclarationForceExternallyVisibleDefinition() const {
3745
3746
FunctionTypeLoc FunctionDecl::getFunctionTypeLoc() const {
3747
const TypeSourceInfo *TSI = getTypeSourceInfo();
3748
-
+ // CHERIOT: The following code diverges from upstream. The previous
3749
+ // code returned a null FunctionTypeLoc when the function was
3750
+ // annotated (impacting getReturnTypeSourceRange too). It is
3751
+ // necessary to provide hints to replace the return type of a
3752
+ // compartment entry point which returns void instead of int.
3753
+ //
3754
+ // https://github.com/llvm/llvm-project/pull/118420
3755
if (!TSI)
3756
return FunctionTypeLoc();
3757
0 commit comments