On Monday, 10 December 2012 at 22:01:37 UTC, Ali Çehreli wrote:
On 12/10/2012 01:52 PM, js.mdnq wrote:

> I want to avoid having to wrap the code with "
> " as it disables highlighting and possibly other
features(intellisense,
> etc...))

The q{} syntax is supposed to help with that issue. Emacs manages syntax highlighting correctly for the q{} strings:

import std.stdio;

void main()
{
    enum s = q{
        writeln("hello world");
    };

    mixin (s);  // <-- s is a string
}

Ali

Thanks, this is definitely a step up. In Visual D, highlighting and intellisense does not work correctly but it does seem to make it easier than using a string directly. (I imagine it is the fault of Visual D for treating the argument of q as different than code)

It should, though, let me do what I want easier than the other methods.

Thanks again!

Reply via email to