Dominique Devienne wrote:
On Tue, Apr 7, 2009 at 12:21 PM, Eric Niebler
wrote: multi-character literals give a nicer compile-time string interface. // With mpl::string mpl::string<'hell','o wo','rld'>
Hi Eric,
I've been lurking on this thread for a while, and I'm intrigued by "multi-character literals". Beside being new to me, a Google search yields little information on them, beside the fact that "The value of a narrow or wide character literal containing more than one character or escape sequence is implementation-defined." Isn't this a problem for mpl::string? Thanks, --DD
"Implementation-defined" means that each compiler vendor is required to document how multi-character literals are assigned integral values. A library like MPL can use this information to provide a specialized implementation for each compiler, presenting the user with a uniform interface. And as it turns out, there is very little variation among compiler vendors around the handling of multi-character literals. So far, just one implementation has sufficed. -- Eric Niebler BoostPro Computing http://www.boostpro.com