Skip to content

Commit

Permalink
Avoid copying parser objects
Browse files Browse the repository at this point in the history
Use of their copy members is deprecated since they have a user-declared
dtor.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@231220 91177308-0d34-0410-b5e6-96231b3b80d8
  • Loading branch information
dwblaikie committed Mar 4, 2015
1 parent bbfda9c commit dcc6701
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions include/llvm/Support/CommandLine.h
Original file line number Diff line number Diff line change
Expand Up @@ -989,7 +989,7 @@ void printOptionDiff(const Option &O, const generic_parser_base &P, const DT &V,
// This is instantiated for basic parsers when the parsed value has a different
// type than the option value. e.g. HelpPrinter.
template <class ParserDT, class ValDT> struct OptionDiffPrinter {
void print(const Option &O, const parser<ParserDT> P, const ValDT & /*V*/,
void print(const Option &O, const parser<ParserDT> &P, const ValDT & /*V*/,
const OptionValue<ValDT> & /*Default*/, size_t GlobalWidth) {
P.printOptionNoValue(O, GlobalWidth);
}
Expand All @@ -998,7 +998,7 @@ template <class ParserDT, class ValDT> struct OptionDiffPrinter {
// This is instantiated for basic parsers when the parsed value has the same
// type as the option value.
template <class DT> struct OptionDiffPrinter<DT, DT> {
void print(const Option &O, const parser<DT> P, const DT &V,
void print(const Option &O, const parser<DT> &P, const DT &V,
const OptionValue<DT> &Default, size_t GlobalWidth) {
P.printOptionDiff(O, V, Default, GlobalWidth);
}
Expand Down

0 comments on commit dcc6701

Please sign in to comment.