singleSpec checks the format specifier and throws if it is invalid, but forgets to throw on %%.
@wolframw created dlang/phobos pull request #7894 "Issue 21738 - std.format.spec: singleSpec should throw on "%%"" mentioning this issue: - Issue 21738 - std.format.spec: singleSpec should throw on "%%" https://github.com/dlang/phobos/pull/7894
dlang/phobos pull request #7894 "Fix Issue 21738 - std.format.spec: singleSpec should throw on "%%"" was merged into master: - 68c7e183d41413c95b37f2e9cf03efa6791bab4c by wolframw: Fix Issue 21738 - std.format.spec: singleSpec should throw on "%%" https://github.com/dlang/phobos/pull/7894