parsing strings at compile-time

Hi Everyone, This is not directly related to any of the boost libraries, but I thought people from this list may find it interesting or useful. The below are links to three posts where I tried to describe how we can parse strings at compile time and convert them to data structures, still at compile-time in C++0x with generalized constant expressions. I do not have enough time to write a library myself, but perhaps someone would be able to use such techniques for their library. I think Regular Expressions library would benefit from this technique if the compiler would be able to check the correctness of a regex. http://akrzemi1.wordpress.com/2011/05/06/compile-time-computations/ http://akrzemi1.wordpress.com/2011/05/11/parsing-strings-at-compile-time-par... http://akrzemi1.wordpress.com/2011/05/20/parsing-strings-at-compile-time-par... Regards, &rzej

On 03/06/2011 17:03, Andrzej Krzemienski wrote:
Hi Everyone, This is not directly related to any of the boost libraries, but I thought people from this list may find it interesting or useful. The below are links to three posts where I tried to describe how we can parse strings at compile time and convert them to data structures, still at compile-time in C++0x with generalized constant expressions. I do not have enough time to write a library myself, but perhaps someone would be able to use such techniques for their library. I think Regular Expressions library would benefit from this technique if the compiler would be able to check the correctness of a regex.
http://akrzemi1.wordpress.com/2011/05/06/compile-time-computations/ http://akrzemi1.wordpress.com/2011/05/11/parsing-strings-at-compile-time-par... http://akrzemi1.wordpress.com/2011/05/20/parsing-strings-at-compile-time-par...
I have personally implemented conversion between Unicode encodings at compile-time (which also works in C++03), but I never really found any compelling use for it.
participants (2)
-
Andrzej Krzemienski
-
Mathias Gaunard