Skip to content

Conversation

maflcko
Copy link
Member

@maflcko maflcko commented Jan 7, 2020

RecursiveMutex better clarifies that the mutex is recursive, see also the standard library naming: https://en.cppreference.com/w/cpp/thread/recursive_mutex

For that reason, and to avoid different people asking me the same question repeatedly (e.g. #15932 (review) ), remove the outdated alias CCriticalSection with a scripted-diff

@practicalswift
Copy link
Contributor

Concept ACK: explicit is better than implicit :)

@DrahtBot
Copy link
Contributor

DrahtBot commented Jan 7, 2020

The following sections might be updated with supplementary metadata relevant to reviewers and maintainers.

Conflicts

Reviewers, this pull request conflicts with the following ones:

  • #17261 (Make ScriptPubKeyMan an actual interface and the wallet to have multiple by achow101)
  • #16528 ([WIP] Native Descriptor Wallets (take 2) by achow101)
  • #10443 (Add fee_est tool for debugging fee estimation code by ryanofsky)

If you consider this pull request important, please also help to review the conflicting pull requests. Ideally, start with the one that should be merged first.

Copy link
Contributor

@promag promag left a comment

Choose a reason for hiding this comment

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

ACK dc0e8b6.

@practicalswift
Copy link
Contributor

ACK dc0e8b6 -- scripted diff looks correct

@jtimon
Copy link
Contributor

jtimon commented Jan 9, 2020

ACK dc0e8b6

@Empact
Copy link
Contributor

Empact commented Jan 13, 2020

ACK dc0e8b6

@fanquake
Copy link
Member

Ugh. Messed up my merge order here, should have done this before #17906. @MarcoFalke can you please rebase.

MarcoFalke added 2 commits January 15, 2020 01:43
-BEGIN VERIFY SCRIPT-
 # Delete outdated alias for RecursiveMutex
 sed -i -e '/CCriticalSection/d'                 ./src/sync.h
 # Replace use of outdated alias with RecursiveMutex
 sed -i -e 's/CCriticalSection/RecursiveMutex/g' $(git grep -l CCriticalSection)
-END VERIFY SCRIPT-
-BEGIN VERIFY SCRIPT-
./contrib/devtools/copyright_header.py update ./
-END VERIFY SCRIPT-
@maflcko
Copy link
Member Author

maflcko commented Jan 14, 2020

Rebased and added another scripted diff to also bump the copyright headers of modified files in one go

@practicalswift
Copy link
Contributor

ACK e09c701 -- scripted diff looks correct

@fanquake fanquake requested review from promag, Empact and jtimon January 15, 2020 00:36
@promag
Copy link
Contributor

promag commented Jan 15, 2020

ACK e09c701

@Empact
Copy link
Contributor

Empact commented Jan 15, 2020

ACK e09c701 diff and scripts look correct

nit: ideally copyrights commit would be separate because unrelated, but all diffs are comments and it's scripted so nbd.

Speaking of, could the copyright script be run automatically / periodically? I understand not wanting to run it via CI, but I would prefer either automatically/periodically or every time via CI over manually/sporadically.

fanquake added a commit that referenced this pull request Jan 15, 2020
…utex

e09c701 scripted-diff: Bump copyright of files changed in 2020 (MarcoFalke)
6cbe620 scripted-diff: Replace CCriticalSection with RecursiveMutex (MarcoFalke)

Pull request description:

  `RecursiveMutex` better clarifies that the mutex is recursive, see also the standard library naming: https://en.cppreference.com/w/cpp/thread/recursive_mutex

  For that reason, and to avoid different people asking me the same question repeatedly (e.g. #15932 (review) ), remove the outdated alias `CCriticalSection` with a scripted-diff

ACKs for top commit:
  Empact:
    ACK e09c701 diff and scripts look correct
  promag:
    ACK e09c701
  practicalswift:
    ACK e09c701 -- scripted diff looks correct

Tree-SHA512: 4bd7b5de1befdcf91dc8f43c127a1fee49679e06895a43216f160344a395c8e426dc68d529fbd2d5e1c215625a5a392dc415b1bce4127316aae7ecf98030c855
@fanquake fanquake merged commit e09c701 into bitcoin:master Jan 15, 2020
@maflcko maflcko deleted the 2001-c2-CC branch January 15, 2020 16:11
deadalnix pushed a commit to Bitcoin-ABC/bitcoin-abc that referenced this pull request Apr 25, 2020
Summary:
-BEGIN VERIFY SCRIPT-
 # Delete outdated alias for RecursiveMutex
 sed -i -e '/CCriticalSection/d'                 ./src/sync.h
 # Replace use of outdated alias with RecursiveMutex
 sed -i -e 's/CCriticalSection/RecursiveMutex/g' $(git grep -l CCriticalSection)
-END VERIFY SCRIPT-

This is a backport of Core [[bitcoin/bitcoin#17891 | PR17891]]

Test Plan:
  ninja all check-all

Reviewers: #bitcoin_abc, jasonbcox

Reviewed By: #bitcoin_abc, jasonbcox

Differential Revision: https://reviews.bitcoinabc.org/D5825
ftrader pushed a commit to bitcoin-cash-node/bitcoin-cash-node that referenced this pull request Aug 17, 2020
Summary:
-BEGIN VERIFY SCRIPT-
 # Delete outdated alias for RecursiveMutex
 sed -i -e '/CCriticalSection/d'                 ./src/sync.h
 # Replace use of outdated alias with RecursiveMutex
 sed -i -e 's/CCriticalSection/RecursiveMutex/g' $(git grep -l CCriticalSection)
-END VERIFY SCRIPT-

This is a backport of Core [[bitcoin/bitcoin#17891 | PR17891]]

Test Plan:
  ninja all check-all

Reviewers: #bitcoin_abc, jasonbcox

Reviewed By: #bitcoin_abc, jasonbcox

Differential Revision: https://reviews.bitcoinabc.org/D5825
@bitcoin bitcoin locked as resolved and limited conversation to collaborators Feb 15, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants