dip: __HERE__ special token

monkyyy crazymonkyyy at gmail.com
Tue Apr 12 23:01:39 UTC 2022


On Monday, 11 April 2022 at 22:48:31 UTC, Alexandru Ermicioi 
wrote:
> You could group your fields in a struct, and use with 
> expression, btw.

Suppose your debugging a block of code with debug printer from 
the dip examples

```d
int foo;
float bar;
bool faz;
alias dp=debugprinter!();
foreach(...){...}
```

to disable faz from being printed you would edit this code to
```d
int foo;
float bar;
alias dp=debugprinter!();
bool faz;
foreach(...){...}
```

if your organizing your variables in a struct you'd have to hunt 
down your usage of faz.

The explicit purpose is to NOT require such structure


More information about the Digitalmars-d mailing list