Better implementation of traits