Skip to content
Snippets Groups Projects
  1. Mar 03, 2020
    • Hans Johnson's avatar
      COMP: Prefer const pointer when value does not change · acc916ed
      Hans Johnson authored
      The check finds function parameters of a pointer type that could be changed to
      point to a constant type instead.
      
      When const is used properly, many mistakes can be avoided. Advantages when
      using const properly:
       - prevent unintentional modification of data;
       - get additional warnings such as using uninitialized data;
       - make it easier for developers to see possible side effects.
      
      This check is not strict about constness, it only warns when the constness will
      make the function interface safer.
      acc916ed
  2. Mar 02, 2020
    • Hans Johnson's avatar
      STYLE: Prefer c++11 'using' to 'typedef' · 7be4043f
      Hans Johnson authored
      The check converts the usage of typedef with using keyword.
      
      cd ${BLDDIR}
      run-clang-tidy.py -extra-arg=-D__clang__ -checks=-*,modernize-use-using  -header-filter=.* -fix
      # https://clang.llvm.org/extra/clang-tidy/checks/modernize-use-using.html
      7be4043f
    • Hans Johnson's avatar
      PERF: readability container size empty · 691d5612
      Hans Johnson authored
      The emptiness of a container should be checked using the empty() method
      instead of the size() method. It is not guaranteed that size() is a
      constant-time function, and it is generally more efficient and also
      shows clearer intent to use empty(). Furthermore some containers may
      implement the empty() method but not implement the size() method. Using
      empty() whenever possible makes it easier to switch to another container
      in the future.
      
      cd
      run-clang-tidy.py -extra-arg=-D__clang__ -checks=-*,readability-container-size-empty  -header-filter=.* -fix
      691d5612
    • Hans Johnson's avatar
      STYLE: Make prototype match definition names · 3b30d0ff
      Hans Johnson authored
      Enforce consistency in large projects, where it often happens that a definition
      of function is refactored, changing the parameter names, but its declaration in
      header file is not updated. With this check, we can easily find and correct
      such inconsistencies, keeping declaration and definition always in sync.
      
      Unnamed parameters are allowed and are not taken into account when comparing
      function declarations
      3b30d0ff
    • Hans Johnson's avatar
      STYLE: Make prototype match definition names · 0fe7214d
      Hans Johnson authored
      Enforce consistency in large projects, where it often happens that a definition
      of function is refactored, changing the parameter names, but its declaration in
      header file is not updated. With this check, we can easily find and correct
      such inconsistencies, keeping declaration and definition always in sync.
      
      Unnamed parameters are allowed and are not taken into account when comparing
      function declarations
      0fe7214d
    • Hans Johnson's avatar
      STYLE: Replace integer literals which are cast to bool. · 2a4c1252
      Hans Johnson authored
      Finds and replaces integer literals which are cast to bool.
      
      cd ${BLDDIR}
      run-clang-tidy.py -extra-arg=-D__clang__ -checks=-*,modernize-use-bool-literals  -header-filter=.* -fix
      2a4c1252
    • Hans Johnson's avatar
      COMP: Use nullptr instead of 0 or NULL · 1c3e193d
      Hans Johnson authored
      The check converts the usage of null pointer constants (eg. NULL, 0) to
      use the new C++11 nullptr keyword.
      
      cd
      run-clang-tidy.py -extra-arg=-D__clang__ -checks=-*,modernize-use-nullptr  -header-filter=.* -fix
      1c3e193d
    • Hans Johnson's avatar
      STYLE: Remove redundant void argument lists · 8a7fe7ac
      Hans Johnson authored
      Find and remove redundant void argument lists.
      8a7fe7ac
    • Hans Johnson's avatar
    • Hans Johnson's avatar
      STYLE: Convert CMake-language commands to lower case · 28b8e6c2
      Hans Johnson authored
      Ancient CMake versions required upper-case commands.  Later command names
      became case-insensitive.  Now the preferred style is lower-case.
      28b8e6c2
    • Hans Johnson's avatar
      STYLE: Use modern path naming · 81d1e737
      Hans Johnson authored
      EXECUTABLE_OUTPUT_PATH is the old executable location variable.
      
      The target property RUNTIME_OUTPUT_DIRECTORY supercedes this variable
      for a target if it is set. Executable targets are otherwise placed in
      this directory.
      81d1e737
    • Brad King's avatar
      Merge topic 'mingw-psapi' · 0e34fbcf
      Brad King authored and Kitware Robot's avatar Kitware Robot committed
      
      a1a261ac CMake: Fix psapi lib name on case-sensitive fs
      
      Acked-by: default avatarKitware Robot <kwrobot@kitware.com>
      Merge-request: !170
      0e34fbcf
  3. Feb 28, 2020
  4. Feb 25, 2020
  5. Feb 19, 2020
  6. Feb 18, 2020
  7. Feb 17, 2020
  8. Feb 14, 2020
  9. Feb 13, 2020
  10. Feb 12, 2020
  11. Nov 15, 2019
  12. Nov 14, 2019
  13. Nov 13, 2019
  14. Nov 11, 2019
    • Paul Smith's avatar
      Terminal: Support GNU make's TTY notification environment variable · dfd0521e
      Paul Smith authored and Brad King's avatar Brad King committed
      Starting with release 4.0, GNU make provides for collecting recipe
      output and printing it all at once after the recipe is complete, as
      well as ensuring that only one rule is printing output at a time.
      This allows parallel builds without mangled output.
      
      However, it means that programs run by make do not have a TTY for
      their stdout or stderr: make is collecting this.
      
      GNU make 4.1 and above will set an environment variable MAKE_TERMOUT
      to a non-empty value if make believes that after it's done collecting
      stdout, the results will be displayed on a TTY.
      
      This patch teaches KWsys to check that environment variable and if
      set, proceed as if output is going to a TTY.
      dfd0521e
  15. Nov 04, 2019
  16. Nov 01, 2019
  17. Oct 31, 2019
  18. Oct 30, 2019
  19. Oct 29, 2019
  20. Oct 16, 2019
  21. Oct 15, 2019
  22. Sep 18, 2019
Loading