]> git.tdb.fi Git - libs/core.git/commit
Make lexical_cast symmetric
authorMikko Rasa <tdb@tdb.fi>
Sat, 1 Dec 2012 09:27:45 +0000 (11:27 +0200)
committerMikko Rasa <tdb@tdb.fi>
Sat, 1 Dec 2012 09:27:45 +0000 (11:27 +0200)
commit42ff7c629b2aa7411963bdcc2259a06b1d1de6d3
treed8a7f500d4f02202110fec9dc064de4401937827
parenteedad559456b8e62ed3b9bd9e8253e5f8bcc02d6
Make lexical_cast symmetric

It has bugged me for a long time that lexical_cast took only the type of
the non-string side as a template argument.  Fix it so that it always
takes both target and source types.  The source type can be deduced, so
this only requires changes to invocations that cast things to strings.
source/io/seekable.cpp
source/stringcodec/except.cpp
source/strings/format.h
source/strings/lexicalcast.h
tests/lexicalcast.cpp