Skip to content

STYLE: Replace new by C++14 std::make_unique#2574

Merged
N-Dekker merged 1 commit intoInsightSoftwareConsortium:masterfrom
N-Dekker:Replace-new-by-std-make_unique
Jun 4, 2021
Merged

STYLE: Replace new by C++14 std::make_unique#2574
N-Dekker merged 1 commit intoInsightSoftwareConsortium:masterfrom
N-Dekker:Replace-new-by-std-make_unique

Conversation

@N-Dekker
Copy link
Copy Markdown
Contributor

@N-Dekker N-Dekker commented Jun 4, 2021

According to Clang-Tidy modernize-make-unique:
https://clang.llvm.org/extra/clang-tidy/checks/modernize-make-unique.html

C++ Core Guidelines, March 11, 2021, R.23: Use make_unique() to make unique_ptrs
http://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines#Rr-make_unique

According to Clang-Tidy `modernize-make-unique`:
https://clang.llvm.org/extra/clang-tidy/checks/modernize-make-unique.html

C++ Core Guidelines, March 11, 2021, R.23: Use make_unique() to make unique_ptrs
http://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines#Rr-make_unique
@github-actions github-actions bot added area:Core Issues affecting the Core module area:Filtering Issues affecting the Filtering module area:IO Issues affecting the IO module area:Numerics Issues affecting the Numerics module type:Style Style changes: no logic impact (indentation, comments, naming) labels Jun 4, 2021
@N-Dekker N-Dekker marked this pull request as ready for review June 4, 2021 14:41
Copy link
Copy Markdown
Member

@hjmjohnson hjmjohnson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Very Nice!

@N-Dekker
Copy link
Copy Markdown
Contributor Author

N-Dekker commented Jun 4, 2021

Honestly, even though I mentioned Clang-Tidy modernize-make-unique, I mostly did the code changes manually. Clang-Tidy Visual Studio integration didn't work very smoothly today, on my laptop 🤔 I tried both Clang Power Tools (https://clangpowertools.com) and the Visual Studio "Code Analysis" Clang-Tidy option (https://docs.microsoft.com/en-us/cpp/code-quality/clang-tidy?view=msvc-160)

@N-Dekker
Copy link
Copy Markdown
Contributor Author

N-Dekker commented Jun 4, 2021

itkPyBufferMemoryLeakTest keeps failing, on ITK.macOS.Python (Azure.Mac-1622805395877): https://open.cdash.org/viewTest.php?onlyfailed&buildid=7266522 That's unrelated to the C++14 upgrade, right?

@hjmjohnson
Copy link
Copy Markdown
Member

@N-Dekker I hope so. It's failing on all the PR's recently clogging up the system.

@N-Dekker N-Dekker merged commit 22bce72 into InsightSoftwareConsortium:master Jun 4, 2021
N-Dekker added a commit to SuperElastix/elastix that referenced this pull request Aug 26, 2021
According to Clang-Tidy modernize-make-unique:
https://clang.llvm.org/extra/clang-tidy/checks/modernize-make-unique.html

C++ Core Guidelines, August 19, 2021, R.23: Use make_unique() to make unique_ptrs
http://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines#Rr-make_unique

Following ITK pull request InsightSoftwareConsortium/ITK#2574 commit InsightSoftwareConsortium/ITK@22bce72 (4 June 2021)
N-Dekker added a commit to SuperElastix/elastix that referenced this pull request Aug 26, 2021
According to Clang-Tidy modernize-make-unique:
https://clang.llvm.org/extra/clang-tidy/checks/modernize-make-unique.html

C++ Core Guidelines, August 19, 2021, R.23: Use make_unique() to make unique_ptrs
http://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines#Rr-make_unique

Following ITK pull request InsightSoftwareConsortium/ITK#2574 commit InsightSoftwareConsortium/ITK@22bce72 (4 June 2021)
N-Dekker added a commit to SuperElastix/elastix that referenced this pull request Aug 26, 2021
According to Clang-Tidy modernize-make-unique:
https://clang.llvm.org/extra/clang-tidy/checks/modernize-make-unique.html

C++ Core Guidelines, August 19, 2021, R.23: Use make_unique() to make unique_ptrs
http://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines#Rr-make_unique

Following ITK pull request InsightSoftwareConsortium/ITK#2574 commit InsightSoftwareConsortium/ITK@22bce72 (4 June 2021)
N-Dekker added a commit to SuperElastix/elastix that referenced this pull request Aug 27, 2021
According to Clang-Tidy modernize-make-unique:
https://clang.llvm.org/extra/clang-tidy/checks/modernize-make-unique.html

C++ Core Guidelines, August 19, 2021, R.23: Use make_unique() to make unique_ptrs
http://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines#Rr-make_unique

Following ITK pull request InsightSoftwareConsortium/ITK#2574 commit InsightSoftwareConsortium/ITK@22bce72 (4 June 2021)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:Core Issues affecting the Core module area:Filtering Issues affecting the Filtering module area:IO Issues affecting the IO module area:Numerics Issues affecting the Numerics module type:Style Style changes: no logic impact (indentation, comments, naming)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants