Also centralizes the knowledge about whether the hashbang is allowed in the
SourceManager. This fixes a bug in tokenize() because previously it just had
to guess.
Swift SVN r6822
around everywhere
Fixes:
rdar://14585108 Code completion does not work at the beginning of the file
rdar://14592634 Code completion returns zero results at EOF in a function
without a closing brace
Swift SVN r6820
This closes out <rdar://problem/14513108> -- sil-opt no longer depends on
ClangImporter or any Clang libraries. In theory, however, forcing a load
of a libSwiftClangImporter.dylib would allow sil-opt to process SIL files
containing Clang imports.
Swift SVN r6700
-Introduce PersistentParserState to represent state persistent among multiple parsing passes.
The advantage is that PersistentParserState is independent of a particular Parser or Lexer object.
-Use PersistentParserState to keep information about delayed function body parsing and eliminate parser-specific
state from the AST (ParserTokenRange).
-Introduce DelayedParsingCallbacks to abstract out of the parser the logic about which functions should be delayed
or skipped.
Many thanks to Dmitri for his valuable feedback!
Swift SVN r6580
This mainly removes the extraneous DiagnosticEngine and SourceMgr from CompilerInvocation.
Instances of these can be found via the CompilerInstance object.
Swift SVN r6496
Add a little dance in the setup of the Clang importer. Now, clients that don't care
about the clang importer don't have to link it in, just don't call setSDKPath()
Swift SVN r6462
* Added a mode in swift-ide-test to test code completion. Unlike c-index-test,
the code completion token in tests is a real token -- we don't need to
count lines and columns anymore.
* Added support in lexer to produce a code completion token.
* Added a parser interface to code completion. It is passed down from the
libFrontend to the parser, but its functions are not called yet.
* Added a sketch of the interface of code completion consumer and code
completion results.
Note: all this is not doing anything useful yet.
Swift SVN r6128