X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=source%2Ftype.h;h=6959e98526669e4482c34d59b26530450c12fedd;hb=3c02de7bf2be5a8c98933a97090d911b41633cd5;hp=5a87a10222a84794341d9a167c94786ae022927f;hpb=a582163d380833b1370ba067a1fd0ad5c2984723;p=libs%2Fdatafile.git diff --git a/source/type.h b/source/type.h index 5a87a10..6959e98 100644 --- a/source/type.h +++ b/source/type.h @@ -1,10 +1,3 @@ -/* $Id$ - -This file is part of libmspdatafile -Copyright © 2010 Mikko Rasa, Mikkosoft Productions -Distributed under the LGPL -*/ - #ifndef MSP_DATAFILE_TYPE_H_ #define MSP_DATAFILE_TYPE_H_ @@ -17,7 +10,8 @@ struct Symbol { std::string name; - Symbol(const std::string &n): name(n) { } + template + Symbol(const T &n): name(lexical_cast(n)) { } template operator T() const { return lexical_cast(name); } };