https://issues.dlang.org/show_bug.cgi?id=16026
Issue ID: 16026 Summary: std.math.frexp!float() wrong for very small subnormal values Product: D Version: D2 Hardware: x86_64 OS: Linux Status: NEW Severity: normal Priority: P1 Component: phobos Assignee: nob...@puremagic.com Reporter: thomas.bock...@gmail.com import std.math, std.traits, std.stdio; T test(T)() if (isFloatingPoint!T) { int exp; return frexp(3 * (T.epsilon * T.min_normal), exp); } void main() { writeln(test!real()); // 0.75 writeln(test!double()); // 0.5?? (But 0.75 on GDC.) writeln(test!float()); // 0.5?? (But 0.75 on GDC.) } --- I tried tracking this down myself in the std.math code, but I couldn't find anything wrong. Maybe it's a codegen bug? --