I wonder if this logic belongs on DataType instead of Attribute.