Skip to content

Conversation

@jtimon
Copy link
Contributor

@jtimon jtimon commented Mar 30, 2017

  • ParseParameters
  • ReadConfigFile
  • ForceSetArg
  • SoftSetArg

Includes:

From the wrappers newly introduced with ArgsManager, these seem currently the easiest to remove.

Copy link
Contributor

@JeremyRubin JeremyRubin left a comment

Choose a reason for hiding this comment

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

utack

src/util.cpp Outdated
Copy link
Contributor

Choose a reason for hiding this comment

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

Any reason to not return a const ref?

Also, ArgsAt is a bit of an odd name, perhaps ArgsFor or something (but maybe not worth the effort to redo this)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

See #9494 (comment) for some reason all your reviews are appearing in #10119 instead of #9494 . Can you make the comments there for other reviewers to get them? Remember after #9494 this PR (#10119) is a single commit (that could be squashed to #9494 or not)

Copy link
Contributor

Choose a reason for hiding this comment

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

oh -- I didn't understand 'includes' to mean builds on the PR. gotcha

src/util.cpp Outdated
Copy link
Contributor

Choose a reason for hiding this comment

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

Should this push_back or replace?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I believe push_back, but it's a good point, I am not sure now.

src/util.cpp Outdated
Copy link
Contributor

Choose a reason for hiding this comment

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

Is the PR too big if you get rid of these?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

The less disruptive to remove are removed in #10119 I'm happy to squash that in #9494
Others are more disruptive to remove, but I'm working on doing it for SoftSetBoolArg and IsArgSet in jtimon/bitcoin@0.14-args-wrappers...jtimon:0.14-args-isargset-wrapper but I'm not sure everybody will like that way of doing it.

src/util.h Outdated
Copy link
Contributor

Choose a reason for hiding this comment

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

why not use multimap?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I was just using the same that was used before. We can move to multimap, what would be the gain?

Copy link
Contributor

Choose a reason for hiding this comment

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

No real gain, just slightly simpler (because multi_map is intended to be used I think exactly in this type of case).

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I thought it was more for when you wanted the elements on the vector to be ordered in certain way or something. Leaving the same structure seems easier to review, but once encapsulated it is easy to make further improvements to ArgsManager's internal implementation.

@jtimon jtimon force-pushed the 0.14-args-wrappers branch from 11b82c4 to 1a52af8 Compare April 4, 2017 15:10
@jtimon
Copy link
Contributor Author

jtimon commented Apr 4, 2017

Needed rebase.

@jtimon jtimon force-pushed the 0.14-args-wrappers branch from c165600 to 9d6c531 Compare April 6, 2017 20:47
@jtimon
Copy link
Contributor Author

jtimon commented May 5, 2017

Incorportated in #9494

@jtimon jtimon closed this May 5, 2017
@bitcoin bitcoin locked as resolved and limited conversation to collaborators Sep 8, 2021
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.

3 participants