Skip to content
  1. Sep 28, 2017
  2. Sep 26, 2017
  3. Sep 20, 2017
  4. Sep 18, 2017
  5. Sep 16, 2017
  6. Sep 15, 2017
    • Douglas Gregor's avatar
      [Module map] Introduce a private module re-export directive. · f0b11de2
      Douglas Gregor authored
      Introduce a new "export_as" directive for top-level modules, which
      indicates that the current module is a "private" module whose symbols
      will eventually be exported through the named "public" module. This is
      in support of a common pattern in the Darwin ecosystem where a single
      public framework is constructed of several private frameworks, with
      (currently) header duplication and some support from the linker.
      
      Addresses rdar://problem/34438420.
      
      llvm-svn: 313316
      f0b11de2
  7. Sep 12, 2017
    • Ilya Biryukov's avatar
      Fix recording preamble's conditional stack in skipped PP branches. · 8f738ac6
      Ilya Biryukov authored
      Summary:
      This fixes PR34547.
      `Lexer::LexEndOfFile` handles recording of ConditionalStack for
      preamble and reporting errors about unmatched conditionalal PP
      directives.
      However, SkipExcludedConditionalBlock contianed duplicated logic for
      reporting errors and clearing ConditionalStack, but not for preamble
      recording.
      
      This fix removes error reporting logic from
      `SkipExcludedConditionalBlock`, unmatched PP conditionals are now
      reported inside `Lexer::LexEndOfFile`.
      
      Reviewers: erikjv, klimek, bkramer
      
      Reviewed By: erikjv
      
      Subscribers: nik, cfe-commits
      
      Differential Revision: https://reviews.llvm.org/D37700
      
      llvm-svn: 313014
      8f738ac6
  8. Sep 11, 2017
    • Vedant Kumar's avatar
      [Lexer] Report more precise skipped regions (PR34166) · 3919a501
      Vedant Kumar authored
      This patch teaches the preprocessor to report more precise source ranges for
      code that is skipped due to conditional directives.
      
      The new behavior includes the '#' from the opening directive and the full text
      of the line containing the closing directive in the skipped area. This matches
      up clang's behavior (we don't IRGen the code between the closing "endif" and
      the end of a line).
      
      This also affects the code coverage implementation. See llvm.org/PR34166 (this
      also happens to be rdar://problem/23224058).
      
      The old behavior (report the end of the skipped range as the end
      location of the 'endif' token) is preserved for indexing clients.
      
      Differential Revision: https://reviews.llvm.org/D36642
      
      llvm-svn: 312947
      3919a501
  9. Sep 08, 2017
  10. Sep 05, 2017
  11. Sep 04, 2017
  12. Aug 31, 2017
    • Boris Kolpackov's avatar
      [modules] Add ability to specify module name to module file mapping (reapply) · d30446fd
      Boris Kolpackov authored
      Extend the -fmodule-file option to support the [<name>=]<file> value format.
      If the name is omitted, then the old semantics is preserved (the module file
      is loaded whether needed or not). If the name is specified, then the mapping
      is treated as just another prebuilt module search mechanism, similar to
      -fprebuilt-module-path, and the module file is only loaded if actually used
      (e.g., via import). With one exception: this mapping also overrides module
      file references embedded in other modules (which can be useful if module files
      are moved/renamed as often happens during remote compilation).
      
      This override semantics requires some extra work: we now store the module name
      in addition to the file name in the serialized AST representation.
      
      Reviewed By: rsmith
      
      Differential Revision: https://reviews.llvm.org/D35020
      
      llvm-svn: 312220
      d30446fd
  13. Aug 30, 2017
    • Victor Leschuk's avatar
      Revert r312105 [modules] Add ability to specify module name to module file mapping · db68911b
      Victor Leschuk authored
      Looks like it breaks win10 builder.
      
      llvm-svn: 312112
      db68911b
    • Boris Kolpackov's avatar
      [modules] Add ability to specify module name to module file mapping · 7a71b4b6
      Boris Kolpackov authored
      Extend the -fmodule-file option to support the [<name>=]<file> value format.
      If the name is omitted, then the old semantics is preserved (the module file
      is loaded whether needed or not). If the name is specified, then the mapping
      is treated as just another prebuilt module search mechanism, similar to
      -fprebuilt-module-path, and the module file is only loaded if actually used
      (e.g., via import). With one exception: this mapping also overrides module
      file references embedded in other modules (which can be useful if module files
      are moved/renamed as often happens during remote compilation).
      
      This override semantics requires some extra work: we now store the module name
      in addition to the file name in the serialized AST representation.
      
      Reviewed By: rsmith
      
      Differential Revision: https://reviews.llvm.org/D35020
      
      llvm-svn: 312105
      7a71b4b6
  14. Aug 24, 2017
    • Erich Keane's avatar
      [Preprocessor] Correct internal token parsing of newline characters in CRLF · 5a2b322e
      Erich Keane authored
      Discovered due to a goofy git setup, the test system-headerline-directive.c 
      (and a few others) failed because the token-consumption will consume only the 
      '\r' in CRLF, making the preprocessor's printed value give the wrong line number 
      when returning from an include. For example:
      
      (line 1):#include <noline.h>\r\n
      
      The "file exit" code causes the printer to try to print the 'returned to the 
      main file' line. It looks up what the current line number is. However, since the 
      current 'token' is the '\n' (since only the \r was consumed), it will give the 
      line number as '1", not '2'. This results in a few failed tests, but more 
      importantly, results in error messages being incorrect when compiling a 
      previously preprocessed file.
      
      Differential Revision: https://reviews.llvm.org/D37079
      
      llvm-svn: 311683
      5a2b322e
  15. Aug 21, 2017
  16. Aug 14, 2017
  17. Aug 13, 2017
  18. Aug 12, 2017
  19. Aug 10, 2017
  20. Aug 09, 2017
  21. Jul 30, 2017
  22. Jul 25, 2017
  23. Jul 20, 2017
  24. Jul 17, 2017
    • Faisal Vali's avatar
      [NFC] Refactor the Preprocessor function that handles Macro definitions and... · ac506d74
      Faisal Vali authored
      [NFC] Refactor the Preprocessor function that handles Macro definitions and rename Arguments to Parameters in Macro Definitions. 
        - Extracted the reading of the tokens out into a separate function.
        - Replace 'Argument' with 'Parameter' when referring to the identifiers of the macro definition (as opposed to the supplied arguments - MacroArgs - during the macro invocation).
      
      This is in preparation for submitting patches for review to implement __VA_OPT__ which will otherwise just keep lengthening the HandleDefineDirective function and making it less comprehensible.
      
      I will also directly update some extra clang tooling that is broken by the change from Argument to Parameter.
      
      Hopefully the bots will stay appeased.
      
      Thanks!
      
      llvm-svn: 308190
      ac506d74
    • Faisal Vali's avatar
      Revert changes from my previous refactoring - will need to fix dependencies in... · 0e54e567
      Faisal Vali authored
      Revert changes from my previous refactoring - will need to fix dependencies in clang's extra tooling (such as clang-tidy etc.).
      
      Sorry about that.
      
      llvm-svn: 308158
      0e54e567
    • Faisal Vali's avatar
      [NFC] Refactor the Preprocessor function that handles Macro definitions and... · 11746b05
      Faisal Vali authored
      [NFC] Refactor the Preprocessor function that handles Macro definitions and rename Arguments to Parameters in Macro Definitions. 
        - Extracted the reading of the tokens out into a separate function.
        - Replace 'Argument' with 'Parameter' when referring to the identifiers of the macro definition (as opposed to the supplied arguments - MacroArgs - during the macro invocation).
      
      This is in preparation for submitting patches for review to implement __VA_OPT__ which will otherwise just keep lengthening the HandleDefineDirective function and making it less comprehensible.
      
      
      Thanks!
      
      llvm-svn: 308157
      11746b05
  25. Jul 14, 2017
    • Olivier Goffart's avatar
      Keep the IdentifierInfo in the Token for alternative operator keyword · 90f981bc
      Olivier Goffart authored
      The goal of this commit is to fix clang-format so it does not merge tokens when
      using the alternative spelling keywords. (eg: "not foo" should not become "notfoo")
      
      The problem is that Preprocessor::HandleIdentifier used to drop the identifier info
      from the token for these keyword. This means the first condition of
      TokenAnnotator::spaceRequiredBefore is not met. We could add explicit check for
      the spelling in that condition, but I think it is better to keep the IdentifierInfo
      and handle the operator keyword explicitly when needed. That actually leads to simpler
      code, and probably slightly more efficient as well.
      
      Another side effect of this change is that __identifier(and) will now work as
      one would expect, removing a FIXME from the MicrosoftExtensions.cpp test
      
      Differential Revision: https://reviews.llvm.org/D35172
      
      llvm-svn: 308008
      90f981bc
Loading