Boost logo

Boost Users :

Subject: Re: [Boost-users] compile time (template or preprocessor) text processing
From: Sebastian Redl (sebastian.redl_at_[hidden])
Date: 2010-12-06 04:45:30


On 05.12.2010 22:04, Laszlo Marak wrote:
> Is there a possibility to generate a std::string from a FILE following some
> rules using template meta-programming (or possibly the preprocessor)?
Sorry, absolutely not. Reading files is completely beyond the template
system, and the preprocessor will interpret it as C++ code, so even if
you could come up with amazingly clever macros to hide all the code (you
can't), you still wouldn't have access to the contents of comments.

Sebastian


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net