now discount.cpp uses Attributes too