Commit Graph

375 Commits

Author SHA1 Message Date
Daniel.Perry
838dc1e189 move append_float_length specialization to the header 2014-12-02 10:20:27 -05:00
Daniel.Perry
334fc54b5d removed unused code 2014-11-25 18:03:54 -05:00
Daniel.Perry
bd0067ee76 made code compile under windows with level 4 warnings 2014-11-25 18:01:09 -05:00
Victor Zverovich
5a5870d3ca n -> size 2014-10-30 07:10:43 -07:00
Victor Zverovich
5c4b6678e4 Compute StringRef size in ctor 2014-10-30 07:05:42 -07:00
Victor Zverovich
709465197a Switch to bootstrap theme 2014-10-10 08:40:35 -07:00
Victor Zverovich
1e63fc7ca0 Comment 2014-10-05 09:34:46 -07:00
Victor Zverovich
04d38a8b14 Update docs 2014-10-01 08:32:01 -07:00
Victor Zverovich
8b9a6e03f6 Test buffer 2014-10-01 08:12:10 -07:00
Victor Zverovich
74dc571ba0 Support signed char and unsigned char strings 2014-09-30 08:15:56 -07:00
Victor Zverovich
d1ded569ff Separate memory management and formatting
Array is split into an abstract Buffer class and a concrete MemoryBuffer class. BasicWriter now does all memory allocation through a Buffer object. Subclasses of BasicWriter may use different buffer types. The new BasicMemoryBuffer class uses the default MemoryBuffer.
2014-09-29 08:48:16 -07:00
Victor Zverovich
5ca3d00e26 Mind the lifetime 2014-09-25 12:15:16 -07:00
Victor Zverovich
a9da3d3852 Fix ArgList::operator[] 2014-09-25 09:31:36 -07:00
Victor Zverovich
65cb43a484 Store type info in uint64_t instead of ULongLong 2014-09-25 07:42:29 -07:00
Victor Zverovich
098a8fdef8 Simplify make_type 2014-09-25 07:14:08 -07:00
Victor Zverovich
75a2ea03a7 Reduce code bloat
Special case C strings because there is no need to handle size for them. Add support for pre-C++11 compilers to make_type.
2014-09-25 07:10:44 -07:00
Victor Zverovich
163178eee1 Make print non-inline 2014-09-25 07:08:25 -07:00
Victor Zverovich
ae8bc36e57 MakeArg -> MakeValue 2014-09-24 08:07:50 -07:00
Victor Zverovich
93b314d3ab Comments 2014-09-24 07:59:23 -07:00
Victor Zverovich
ec1aea34e6 Refactor type processing 2014-09-24 07:48:45 -07:00
Victor Zverovich
ab6e759291 pointer_value -> pointer 2014-09-23 08:21:58 -07:00
Victor Zverovich
d2973766ea ArgBase -> Value 2014-09-23 08:11:03 -07:00
Victor Zverovich
beb00edf73 Store types in ArgList instead of Arg 2014-09-23 07:59:43 -07:00
Victor Zverovich
1d4640415d Pass ArgList by value
This improve bloat test results:
Old stripped size: 67680 (optimized)
New stripped size: 59488 (optimized)
2014-09-21 08:08:52 -07:00
Victor Zverovich
b9a568b1dd Add support for custom memory allocator to BasicWriter 2014-09-19 07:51:42 -07:00
Victor Zverovich
6a98f42336 Add support for custom allocators 2014-09-18 09:07:40 -07:00
Victor Zverovich
886ad20a9d Remove unused size argument from Array's ctor. 2014-09-12 17:20:36 -07:00
Victor Zverovich
1e9ca17b9d Workaround Windows crap. 2014-09-12 13:42:22 -07:00
Victor Zverovich
d59fbdcd4a Increase the maximum number of formatting arguments on compilers without variadic templates to 15. 2014-09-11 21:18:36 -07:00
Victor Zverovich
f2c9df8e9f Move safe_strerror to anonymous namespace. 2014-09-05 08:44:41 -07:00
Victor Zverovich
88e0db8486 Test format_error_code. 2014-09-05 08:04:26 -07:00
Victor Zverovich
22f75d8b6d Don't throw exceptions from error formatting functions. Gracefully fallback to a less descriptive message instead. 2014-09-03 08:03:05 -07:00
Victor Zverovich
5debb2aa86 Refactor error reporting to reduce duplication. 2014-08-29 08:16:10 -07:00
Victor Zverovich
605d2600f8 Improve error reporting. 2014-08-29 07:45:55 -07:00
Victor Zverovich
271fa8c908 Improve handling of format strings in custom arguments. 2014-08-29 07:23:54 -07:00
Victor Zverovich
3947a7a98c Move check_sign to anonymous namespace. 2014-08-29 06:57:53 -07:00
Victor Zverovich
c57d7a506f Factor out argument processing logic common between format and printf to FormatterBase::{next_arg,get_arg}. 2014-08-28 08:05:47 -07:00
Victor Zverovich
56fc525e98 Get rid of FormatterBase::error_. 2014-08-28 07:48:55 -07:00
Victor Zverovich
526b7fc91d Throw exception in parse_nonnegative_int if the number is too big. 2014-08-28 06:42:59 -07:00
Victor Zverovich
9646e38c3b Don't use error_ in parse_arg_index. 2014-08-27 09:13:42 -07:00
Victor Zverovich
42de4f1f7d Get rid of FormatErrorReporter. 2014-08-27 08:24:31 -07:00
Victor Zverovich
dd4323f31c Add fprintf and write docs. 2014-08-21 08:49:13 -07:00
Victor Zverovich
f9561671cf Write docs. 2014-08-21 07:30:00 -07:00
Victor Zverovich
406c6123fb Cleanup 2014-08-19 08:47:38 -07:00
Victor Zverovich
fb32161fa4 Move implementation specific stuff from format.h to format.cc. 2014-08-15 08:40:03 -07:00
Victor Zverovich
431b556951 Add FMT_ prefix to SPECIALIZE_MAKE_UNSIGNED. 2014-08-07 07:42:55 -07:00
Victor Zverovich
6cd1563eac Add a size argument to Array ctor. 2014-08-06 07:17:03 -07:00
Victor Zverovich
58dfe5c9f7 Make format_decimal inline. 2014-08-01 08:49:16 -07:00
Victor Zverovich
be9356b651 Specialize MakeUnsigned for all signed integer types. 2014-07-31 21:23:49 -07:00
Victor Zverovich
d81fafc295 Fix tests on MSVC, take 2. 2014-07-31 07:43:14 -07:00