mirror of
https://github.com/matrix-construct/construct
synced 2024-10-02 05:38:53 +02:00
ircd::fmt: Add floating point notation format policy.
This commit is contained in:
parent
400b306833
commit
b62c4205a3
1 changed files with 7 additions and 0 deletions
|
@ -1119,6 +1119,13 @@ const
|
||||||
{
|
{
|
||||||
return _precision_ > 0;
|
return _precision_ > 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static int floatfield(const double &)
|
||||||
|
{
|
||||||
|
return _precision_ > 0?
|
||||||
|
fmtflags::fixed:
|
||||||
|
fmtflags::scientific;
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
karma::rule<char *, double()> rule
|
karma::rule<char *, double()> rule
|
||||||
|
|
Loading…
Reference in a new issue