This could be in a separate file, say approx.d, if doing so didn't crash dmd. see https://issues.dlang.org/show_bug.cgi?id=18839
5.should.be.approximately(5.1, 0.11); 5.should.approximately(0.11).be(5.1); 0.should.approximately(1.1).equal(1.0); 0.should.approximately(1.1).equal(-1.0); 0.should.not.approximately(0.1).equal(1); 42.3.should.be.approximately(42.3, 1e-3);