Skip to content

Instantly share code, notes, and snippets.

@deque-blog
Last active August 22, 2017 07:37
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save deque-blog/5f5d289cf9c063eaf443bb3b00dad7ee to your computer and use it in GitHub Desktop.
Save deque-blog/5f5d289cf9c063eaf443bb3b00dad7ee to your computer and use it in GitHub Desktop.
template<Currency MoneyCurrency>
class Money
{
public:
Money() : m_amount(Amount{}) {}
explicit Money(Amount amount) : m_amount(amount) {}
Amount amount() const { return m_amount; }
private:
Amount m_amount;
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment