RegexBackedCSourceParserTest.groovy

Clone Tools
  • last updated a few seconds ago
Constraints
Constraints: committers
 
Constraints: files
Constraints: dates
spelling: resolvable

Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>

  1. … 9 more files in changeset.
Convert dependency management related subprojects to kotlin-dsl (#4498)

This PR also fixes the dependency declarations wrt. api/impl separation

for these and related projects.

It fixes two places in production/test code where dependencies

leaked into the classpath and the wrong classes where imported.

  1. … 21 more files in changeset.
Revert unecessary changes

  1. … 2 more files in changeset.
Move indexing logic of macros inside `DefaultIncludeDirectives`

  1. … 10 more files in changeset.
Create lookup table for macros and macro functions

  1. … 9 more files in changeset.
Changed C/C++ dependency analysis to correctly handle macro expanding (or not) the arguments of a macro function when used in a token concatenation expression.

    • -69
    • +91
    ./RegexBackedCSourceParserTest.groovy
  1. … 11 more files in changeset.
Changed C/C++ dependency analysis to correctly handle a chain of token concatenation expressions, and allow token concatenation expressions to be used as macro function call parameters.

    • -29
    • +71
    ./RegexBackedCSourceParserTest.groovy
  1. … 5 more files in changeset.
Some changes to C/C++ dependency analysis to better handle macro functions that use token concatenation to produce another macro function call. Also changed resolution of an `#include` to an include path to avoid doing work that has already been done for the current source file to calculate macro values.

    • -4
    • +57
    ./RegexBackedCSourceParserTest.groovy
  1. … 10 more files in changeset.
Changed C/C++ dependency analysis to handle more kinds of macro function call parameters. Specifically, handle empty parameters, provide an implicit empty parameter when a parameter is missing, allow various token sequences to be provided as a parameter.

    • -4
    • +21
    ./RegexBackedCSourceParserTest.groovy
  1. … 18 more files in changeset.
Changed C/C++ dependency analysis to handle more kinds of macro function call parameters within a macro function body. Specifically, substitute macro parameters into all arguments of the macro call and understand arguments that are wrapped in parentheses.

    • -15
    • +90
    ./RegexBackedCSourceParserTest.groovy
  1. … 10 more files in changeset.
Changed C/C++ dependency analysis to correctly handle token concatenation expressions in macro function bodies that are invoked from another macro function.

    • -16
    • +34
    ./RegexBackedCSourceParserTest.groovy
  1. … 12 more files in changeset.
Changed C/C++ dependency analysis to understand preprocessor token concatenation expressions in macro bodies (eg X##Y).

    • -11
    • +78
    ./RegexBackedCSourceParserTest.groovy
  1. … 15 more files in changeset.
Changed C/C++ dependency analysis to handle "function-like" macros whose value is a macro function call.

    • -0
    • +18
    ./RegexBackedCSourceParserTest.groovy
  1. … 9 more files in changeset.
Changed C/C++ dependency analysis to handle more kinds of macro function call parameters. Specifically, handle parameters that are quoted strings, system include paths and macro function calls, in addition to macros (that were already handled).

    • -13
    • +18
    ./RegexBackedCSourceParserTest.groovy
  1. … 15 more files in changeset.
Changed C/C++ dependency analysis to handle macros whose body is a macro function call.

    • -18
    • +68
    ./RegexBackedCSourceParserTest.groovy
  1. … 21 more files in changeset.
Changed C/C++ dependency analysis to start to understand "function-like" macros that take parameters. Specifically, handle function invocations whose parameters are macro names on functions whose bodies are either a constant, a macro or one of the function parameters.

    • -9
    • +79
    ./RegexBackedCSourceParserTest.groovy
  1. … 17 more files in changeset.
Changed C/C++ dependency analysis to extract the parameters of a call to a 'function-like' macro. These aren't used yet.

Also slightly improved the "could not find this include" info message.

    • -17
    • +70
    ./RegexBackedCSourceParserTest.groovy
  1. … 23 more files in changeset.
Recognize "function-like" macros with parameters during native compile include file dependency analysis. These are not resolved yet, so when referenced by an include directive result in an unresolved include file (and so all of the include directories are considered inputs of the compilation).

    • -18
    • +86
    ./RegexBackedCSourceParserTest.groovy
  1. … 9 more files in changeset.
Separated the types to represent 'object-like' macros and 'function-like' macros in parsed native source.

    • -8
    • +24
    ./RegexBackedCSourceParserTest.groovy
  1. … 19 more files in changeset.
Handle "function-like" macros with no parameters during native compile include file dependency analysis.

    • -24
    • +124
    ./RegexBackedCSourceParserTest.groovy
  1. … 11 more files in changeset.
Expand macro values when resolving include files during native compile include file dependency analysis.

Also recognize "function-like" macros used in include directives and macro bodies, for example `#include HEADER()`. These aren't expanded yet and so when referenced by an include directive the include will be treated as unresolved.

    • -11
    • +53
    ./RegexBackedCSourceParserTest.groovy
  1. … 11 more files in changeset.
Don't retain the value of a c preprocessor #define directive for when the value is not something that can be resolved to an include value.

    • -11
    • +48
    ./RegexBackedCSourceParserTest.groovy
  1. … 8 more files in changeset.
Fixed an issue in native compile dependency analysis where a macro is defined in an include file already included by the current source file.

  1. … 12 more files in changeset.
Changed the C/C++ parser to recognize macro definitions. These aren't used in the dependency analysis yet.

    • -9
    • +70
    ./RegexBackedCSourceParserTest.groovy
  1. … 11 more files in changeset.
Removing string views from SourceIncludes

+review REVIEW-5419

  1. … 9 more files in changeset.
Reworking DefaultSourceIncludes to be a bit smarter and remove SourceDetails

+review REVIEW-5419

    • -28
    • +33
    ./RegexBackedCSourceParserTest.groovy
  1. … 18 more files in changeset.
Requiring prefix header to be the first declared header in a source file in order to use PCH

+review REVIEW-5419

    • -1
    • +19
    ./RegexBackedCSourceParserTest.groovy
  1. … 8 more files in changeset.
Fix regex for finding #includes

Allow no whitespace between #directive and file name.

+review REVIEW-5278

  1. … 1 more file in changeset.
Renamed org.gradle.language.nativebase -> org.gradle.language.nativeplatform

    • -0
    • +442
    ./RegexBackedCSourceParserTest.groovy
  1. … 90 more files in changeset.