Skip to content

Commit 483d835

Browse files
committed
[AST/ASTMangler] Fix linker error for SWIFT_BUILD_ONLY_SYNTAXPARSERLIB build
With such a build we avoid linking the `clangAST` library.
1 parent 88ecae4 commit 483d835

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

lib/AST/ASTMangler.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1491,6 +1491,10 @@ void ASTMangler::appendImplFunctionType(SILFunctionType *fn) {
14911491
Optional<ASTMangler::SpecialContext>
14921492
ASTMangler::getSpecialManglingContext(const ValueDecl *decl,
14931493
bool useObjCProtocolNames) {
1494+
#if SWIFT_BUILD_ONLY_SYNTAXPARSERLIB
1495+
return None; // not needed for the parser library.
1496+
#endif
1497+
14941498
// Declarations provided by a C module have a special context mangling.
14951499
// known-context ::= 'So'
14961500
//

0 commit comments

Comments
 (0)