mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
Ensure that buffers containing Clang swift_attr attributes are parsed as attributes
Previously, they were being parsed as top-level code, which would cause errors because there are no definitions. Introduce a new GeneratedSourceInfo kind to mark the purpose of these buffers so the parser can handle them appropriately.
This commit is contained in:
@@ -972,6 +972,7 @@ public:
|
||||
case GeneratedSourceInfo::DefaultArgument:
|
||||
case GeneratedSourceInfo::ReplacedFunctionBody:
|
||||
case GeneratedSourceInfo::PrettyPrinted:
|
||||
case GeneratedSourceInfo::Attribute:
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user