|
Boost : |
Subject: [boost] ΣÏεÏ: [TypeSort] Automatic type sorting
From: costis glynos (cosglyn_at_[hidden])
Date: 2015-03-20 12:13:12
Sweet! Thanks for bringing this to my attention.
ΣÏÎ¹Ï 4:04 μ.μ. ΠαÏαÏκεÏ
ή, 20 ÎαÏÏίοÏ
2015, ο/η Mathias Gaunard <mathias.gaunard_at_[hidden]> ÎγÏαÏε:
On 20/03/2015 16:59, costis glynos wrote:
> Hello,Is there any interest in a library which automatically sorts types from smallest to largest at compile time?The benefit would be the automatic Data Structure Alignment and potential improvement in performance.Foo<int,bool,Custom16ByteType,char,double,short> foo_1; //normal
> Foo<int,bool,Custom16ByteType,char,double,short> foo_2; //using the TypeSort
> output:
> size of foo_1 = 48
> size of foo_2 = 32 Kind Regards,
There is already a sort meta-function in Boost.MPL.
<http://www.boost.org/doc/libs/1_57_0/libs/mpl/doc/refmanual/sort.html>
_______________________________________________
Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk