1. 13 Aug, 2021 2 commits
  2. 12 Aug, 2021 1 commit
  3. 09 Aug, 2021 3 commits
    • [pre-commit.ci] pre-commit autoupdate (#3185) · 0be2ea06
      updates:
      - [github.com/asottile/pyupgrade: v2.23.1 → v2.23.3](https://github.com/asottile/pyupgrade/compare/v2.23.1...v2.23.3)
      
      Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
      pre-commit-ci[bot] committed
    • PYBIND11_NOINLINE-related cleanup. (#3179) · 4c7e509f
      * Removing pragma for GCC -Wattributes, fixing forward declarations.
      
      * Introducing PYBIND11_NOINLINE_FWD to deal with CUDA, GCC7, GCC8.
      
      * Updating PYBIND11_NOINLINE_DCL in Doxyfile.
      
      * Trying noinline, noinline for {CUDA, GCC7, GCC8}
      
      * Trying noinline, inline for {CUDA, GCC7, GCC8}
      
      * Adding GCC -Wattributes `pragma` in 3 header files.
      
      * Introducing PYBIND11_NOINLINE_GCC_PRAGMA_ATTRIBUTES_NEEDED, used in 9 header files.
      
      * Removing ICC pragma 2196, to see if it is still needed.
      
      * Trying noinline, noinline for ICC
      
      * Trying noinline, inline for ICC
      
      * Restoring ICC pragma 2196, introducing PYBIND11_NOINLINE_FORCED, defined for testing.
      
      * Removing code accidentally left in (was for experimentation only).
      
      * Removing one-time-test define.
      
      * Removing PYBIND11_NOINLINE_FWD macro (after learning that it makes no sense).
      
      * Testing with PYBIND11_NOINLINE_DISABLED. Minor non-functional enhancements.
      
      * Removing #define PYBIND11_NOINLINE_DISABLED (test was successful).
      
      * Removing PYBIND11_NOINLINE_FORCED and enhancing comments for PYBIND11_NOINLINE.
      
      * WIP stripping back
      
      * Making -Wattributes pragma in pybind11 specific to GCC7, GCC8, CUDA.
      Ralf W. Grosse-Kunstleve committed
    • maint(perf): Optimize Numpy constructor to remove copies by value. (#3183) · ff590c12
      * maint(perf): Optimize Numpy Constructor with additional std::move
      
      * Add more moves
      Aaron Gokaslan committed
  4. 07 Aug, 2021 1 commit
  5. 06 Aug, 2021 5 commits
    • test_eval: Show example of working closure (#2743) · 6ac8efe5
      * test_eval: Show example of working closure
      
      * Extend test_eval_closure with weirder examples of closures for py::eval
      
      Co-authored-by: Yannick Jadoul <yannick.jadoul@belgacom.net>
      Co-authored-by: Aaron Gokaslan <skylion.aaron@gmail.com>
      Eric Cousineau committed
    • Removing GCC -Wunused-but-set-parameter from pragma block at the top of pybind11.h (#3164) · af700733
      * Cleanup triggered by work on pragma for GCC -Wunused-but-set-parameter.
      
      * Backing out changes to eigen.h (to be worked on later).
      
      * Adding PYBIND11_WORKAROUND_INCORRECT_GCC_UNUSED_BUT_SET_PARAMETER in type_caster_base.h (apparently needed only for older GCCs).
      
      * Apparently older compilers need a simpler overload for silence_unused_warnings().
      
      * clang C++11 compatibility: removing constexpr
      
      * Special case for MSVC 2017: `constexpr void` return
      
      * Trying again without the silence_unused_warnings(const int *) overload.
      
      * Separate macros for ALL_GCC, OLD_GCC_UNUSED_BUT_SET_PARAMETER
      
      * Changing to __GNUC__ <= 2 (turning off)
      
      * Refined condition for PYBIND11_WORKAROUND_INCORRECT_OLD_GCC_UNUSED_BUT_SET_PARAMETER.
      
      * Quick experiment trying out suggestion by @henryiii
      
      * Introducing macro: PYBIND11_INT_ARRAY_WORKING_AROUND_MSVC_CLANG_ISSUES
      
      * Trying henryiii@ (void) expander idea.
      
      * fix: apply simpler expression with fewer workarounds
      
      * Purging new-but-already-obsoleted  macro, made possible by @henryiii's commit.
      
      * Renaming `ALL_GCC` macro back to just `GCC` (because there is no `OLD` anymore, luckily).
      
      * [actions skip] Adding "All GCC versions" to comment, to be clear about it.
      
      Co-authored-by: Henry Schreiner <henryschreineriii@gmail.com>
      Ralf W. Grosse-Kunstleve committed
    • maint(clang-tidy): Bugprone enable checks (#3166) · 3893f37b
      * Enable bugprone checks
      
      * Reset delta and massage config
      
      * Start to apply bugprone fixes
      
      * try to fix minor bug
      
      * Fix later
      
      * Fix perfect forwarding bugprone
      
      * Remove nolint
      
      * undo constructor delete
      
      * Fix bugprone-perfect-forwarding again
      
      * Remove TODO
      
      * Add another nolint for bugprone-exception-escape in scoped interpreter
      
      * Fix remaining bugprone errors
      
      * Properly apply bugprone-macro-parantheses
      
      * Redo formatting and remove bugprone nolint
      
      * Add coment and revert more whitespace changes
      
      * Fix typo
      
      * Fix parsing bug
      
      * Add back comma
      
      * Fix clang-tidy issue
      
      * Apply remaining clang-tidy fixes
      Aaron Gokaslan committed
  6. 03 Aug, 2021 7 commits
  7. 30 Jul, 2021 4 commits
  8. 29 Jul, 2021 3 commits
  9. 28 Jul, 2021 1 commit
  10. 27 Jul, 2021 4 commits
  11. 26 Jul, 2021 4 commits
  12. 21 Jul, 2021 2 commits
    • Specified encoding in setup.py calls of open() (#3137) · e58c6897
      * Specified encoding in setup.py calls of open()
      
      * Fix for Python2
      
      Co-authored-by: Karsten Bock <karsten.bock@dlr.de>
      ka-bo committed
    • Feature/local exception translator (#2650) · d65edfb0
      * Create a module_internals struct
      
      Since we now have two things that are going to be module local, it felt
      correct to add a struct to manage them.
      
      * Add local exception translators
      
      These are added via the  register_local_exception_translator function
      and are then applied before the global translators
      
      * Add unit tests to show the local exception translator works
      
      * Fix a bug in the unit test with the string value of KeyError
      
      * Fix a formatting issue
      
      * Rename registered_local_types_cpp()
      
      Rename it to get_registered_local_types_cpp() to disambiguate from the
      new member of module_internals
      
      * Add additional comments to new local exception code path
      
      * Add a register_local_exception function
      
      * Add additional unit tests for register_local_exception
      
      * Use get_local_internals like get_internals
      
      * Update documentation for new local exception feature
      
      * Add back a missing space
      
      * Clean-up some issues in the docs
      
      * Remove the code duplication when translating exceptions
      
      Separated out the exception processing into a standalone function in the
      details namespace.
      
      Clean-up some comments as per PR notes as well
      
      * Remove the code duplication in register_exception
      
      * Cleanup some formatting things caught by clang-format
      
      * Remove the templates from exception translators
      
      But I added a using declaration to alias the type.
      
      * Remove the extra local from local_internals variable names
      
      * Add an extra explanatory comment to local_internals
      
      * Fix a typo in the code
      jesse-sony committed
  13. 20 Jul, 2021 2 commits
  14. 17 Jul, 2021 1 commit