[PATCH] D25497: [Format] Add more ways to format numbers

Zachary Turner via llvm-commits llvm-commits at lists.llvm.org
Tue Oct 11 21:58:43 PDT 2016


zturner created this revision.
zturner added a reviewer: mehdi_amini.
zturner added a subscriber: llvm-commits.
Herald added subscribers: mgorny, beanz.

This is some preliminary helpers and utilities that I've been working on to support my formatting library.  These are all useful independently of the formatting library, and I'm not committing anything related to the library itself until this is more complete.  But I think it's a good idea to have this review separately so it can be more focused on the details of formatting logic (negative signs, decimals, etc) rather than library machinery.

Note that the top-level functions being modified here (i.e. `write_long`, `write_ulong`, etc) are the same functions used by `llvm::raw_ostream::operator<<`, so this code is being exercised today (albeit with only one set of trivial parameters)


https://reviews.llvm.org/D25497

Files:
  include/llvm/Support/NativeFormatting.h
  lib/Support/NativeFormatting.cpp
  lib/Support/raw_ostream.cpp
  unittests/Support/CMakeLists.txt
  unittests/Support/NativeFormatTests.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D25497.74322.patch
Type: text/x-patch
Size: 37523 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20161012/3a37c875/attachment.bin>


More information about the llvm-commits mailing list