Traits usage sketch! #10
the-moisrex
started this conversation in
Ideas
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I'm using here as an sketch to see which way is the best way to implement.
Example codes of possible implementations:
Ideas about using
Traits
in a classThe goal here is to see which way is the best way to get a string type out of traits type. I think all of them are implementable but which one is the best way? String type is just an example, but other types like Logger and others that will be added later should also be considered.
the type itself chooses the allocator type
using a traits feature type (overkill or necessary??)
minimal type with no traits; this is the perfect choice when possible
using a daddy type which solves all of these issues and more
using a special parent for each type (also we would need
enabled_allocator
,enabled_logger
, ...):Beta Was this translation helpful? Give feedback.
All reactions