[libc] add exponent format to printf
authorMichael Jones <michaelrj@google.com>
Thu, 1 Dec 2022 23:29:15 +0000 (15:29 -0800)
committerMichael Jones <michaelrj@google.com>
Thu, 22 Dec 2022 18:20:59 +0000 (10:20 -0800)
commit51126518261a061624110b013d6cc0a414488f5b
treee44a5465530b7e7baff5d36863fb85c4e1cc83cc
parentf85cc6009aa790dd9970981408401072702ea886
[libc] add exponent format to printf

Add support for the %e/E conversion in printf, as well as unit tests. It
does not yet support long doubles.

Reviewed By: sivachandra

Differential Revision: https://reviews.llvm.org/D140042
libc/src/__support/float_to_string.h
libc/src/stdio/printf_core/converter.cpp
libc/src/stdio/printf_core/float_dec_converter.h
libc/test/src/stdio/sprintf_test.cpp