This makes it easier to follow the docs.
Move 2 documented unittests under isTerminator overload.
Tweak isWhite example to use `\t`, not just a single space.
For HTTP, the response body encoding is specified in the
"Content-Type" header, e.g.: "Content-Type: application/json;
charset=utf-8".
MDN says:
> - `charset`: Indicates the character encoding standard used.
> The value is **case insensitive but lowercase is preferred**.
However, `_decodeContent` was comparing the encoding with the exact
string "UTF-8", which causes most HTTP requests to go through the slow
path.
Fix this by using `icmp`, like elsewhere in the module for
case-insensitive string comparisons.
* std.conv: factor out writeTextImpl from textImpl
* std.conv: add writeText, writeWText, writeDText
These are variants of text, wtext, and dtext that write their output to
an output range instead of returning a string.
Fixes#10550
* Add changelog entry for writeText
* reduce: Document Acc, Elem order in most visible place
* Reduce doesn't enforce predicates
* Reduce: Document behaviour on range with 1 elem
* Doc: Remove references to implemententation detail
Accumulator is the commonly used term for this concept.
* Fix#9585 Add check `variant` alignment
There has been code that handles alignment for a long time
now, and while this module is unlikely to be touched anymore, create a
regression test so the issue can be closed.
* Apparently double is 32bit aligned on x86
The current contraints have been implemented in #3837 to make `each`
behave more like `foreach` and automatically destructure tuples.
I haven't publically documented this behavior because it is probably
better these days to use `bind` for that.
just return the value and assign it to the receiver. Renamed the
conversion function and also cleaned up all the `typeof` calls, which
were very verbose.
This ports the fixes from abs(T)(ComplexT) regarding NaN and skipping
potentially inaccuracy inducing mathematical no-ops when one arg is 0 to
hypot. Both functions do the same thing and should be deduplicated.
hypot also has some logic regarding under and overflows, and while I
don't fully understand it, it should probably not be removed for complex
numbers.
Strictly speaking, the Kelvin scale is not measured in degrees, so the
previous name was incorrect. Changing it in all cases preserves
consistency.
Fixes#10540
This is a simple and straightforward trait. It just says whether the
template argument is a type or not. It has the same functionality as the
trait with the same name in std.traits. However, the implementation is
different. The std.traits version just has an alias overload and uses an
is expression, whereas it seemed like it would probably be more
efficient to split the trait into two and have the kind of argument
determine the result, since the compiler has to go through the work of
deciding whether the argument matches already, though I don't know
enough about the compiler implementation to know for sure that this
implementation is better. Either way, it can be changed later if it's
determined that the std.traits implementation is better.