Remove calls to impure mathlib functions.
Implement pure floor()/ceil().
Implement pure tan().
Implement pure atan().
Implement pure atan2().
Implement pure exp().
Implement pure expm1().
Implement pure exp2().
Implement pure log().
Implement pure log10().
Implement pure log1p().
Implement pure log2().
Implement pure lrint().
Implement pure pow().
Fixup std.math unittests for new math implementations.
Add unittest for issue 9599, plus some other byLine cases
Fix unreferencing ByLine.file once empty

The file handle was not released for an empty text file.
Also, do not pretend empty() is const.
Don't assume wrapped range has a const empty()
Fix Issue 9599 - File.byLine doesn't function properly with take

Calling take could wrongly pop an extra line from the range.
Solved by making ByLine use reference-counting.

Note: Just changing ByLine not to eagerly read the next line was not
sufficient to handle all cases properly (plus that makes empty() less
efficient).

Note: ByLine was documented until recently.
Don't let ByLine degenerate to a ByLineImpl