Mercurial > hg > openttd
changeset 15463:579d5d422892 draft
(svn r20112) -Codechange: Prevent implicit use of CommandCost constructors.
author | terkhen <terkhen@openttd.org> |
---|---|
date | Sat, 10 Jul 2010 19:59:31 +0000 |
parents | fd70c2a4db8a |
children | e526f1e34127 |
files | src/command_type.h |
diffstat | 1 files changed, 2 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/src/command_type.h +++ b/src/command_type.h @@ -35,13 +35,13 @@ /** * Creates a command return value the is failed with the given message */ - CommandCost(StringID msg) : expense_type(INVALID_EXPENSES), cost(0), message(msg), success(false) {} + explicit CommandCost(StringID msg) : expense_type(INVALID_EXPENSES), cost(0), message(msg), success(false) {} /** * Creates a command cost with given expense type and start cost of 0 * @param ex_t the expense type */ - CommandCost(ExpensesType ex_t) : expense_type(ex_t), cost(0), message(INVALID_STRING_ID), success(true) {} + explicit CommandCost(ExpensesType ex_t) : expense_type(ex_t), cost(0), message(INVALID_STRING_ID), success(true) {} /** * Creates a command return value with the given start cost and expense type