
I like this idea. If we need macro expansion, we can do that (and should be doing it) more formally and safer using TH. Ideally conditional compilation should be also done using TH, but it might be overkill for some use cases. On 5/6/2015 10:18 PM, Johannes Waldmann wrote:
There is maybe another option: do what csharp does.
Define a reduced "preprocessor" (for conditional compilation, but without macro expansion) as part of the language. (cf. https://msdn.microsoft.com/en-us/library/ed8yd1ha.aspx )
They must have have had good reasons for doing it this way.
- J.W.
PS: I was trying to add a proper reference (to the language spec) but this seems hard. It is Section 9.5 of ECMA-334. For viewing the newer specs, it seems you need to have MS-Word or VS installed. See also http://stackoverflow.com/questions/13467103/ _______________________________________________ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://mail.haskell.org/cgi-bin/mailman/listinfo/haskell-cafe