On Monday, 3 December 2018 at 06:55:50 UTC, Nicholas Wilson wrote:
On Monday, 3 December 2018 at 06:09:21 UTC, Joel wrote:
[...]
https://run.dlang.io/is/h0ArAB
works for me. If you want it as a string not char[] then
byLineCopy should work, if not just `.idup` `line`.
Oh, I was using std.
On Monday, 3 December 2018 at 06:09:21 UTC, Joel wrote:
I can't seem to get this to work!
```
foreach(line; File("help.txt").byLine) {
writeln(line.stripLeft);
```
With the code above, I get this compile error:
source/app.d(360,36): Error: template
std.algorithm.mutation.stripLeft cannot d
I can't seem to get this to work!
```
foreach(line; File("help.txt").byLine) {
writeln(line.stripLeft);
```
With the code above, I get this compile error:
source/app.d(360,36): Error: template
std.algorithm.mutation.stripLeft cannot deduce function from
argument types !()(char[]), candidat
On Saturday, 1 December 2018 at 19:02:54 UTC, H. S. Teoh wrote:
But that's precisely the problem. It's not always possible to
tell whether a variable has been initialized. E.g.:
To me, the possibility of a "false positive" doesn't preclude the
use of a warning unless that possibility is lar
On Saturday, 1 December 2018 at 19:02:54 UTC, H. S. Teoh wrote:
In the above contrived example, Artin's conjecture is implied
by the Riemann hypothesis, so the second if statement would
only run if p is initialized. But there is no way the compiler
is going to be able to deduce this, especial
On Sunday, 2 December 2018 at 17:59:56 UTC, Paul Backus wrote:
The normal way to do this would be to make bar a template and
have the program that uses it pass these parameters to it as
template arguments.
Why didn't I think of that?
It's just initializing a library, of course!
Thank you for y
On Sunday, 2 December 2018 at 14:50:05 UTC, Sjoerd Nijboer wrote:
The idea being that bar can be packed in a library and the
program that includes this library can decide what parameters
will be added to foo whitout any runtime overhead and ugly
looking syntax.
The normal way to do this would
I would like to do something like
`
dmd --buildversion=fooCollection{"a", "b", "c"} -run app.d
...
void bar()
{
static foreach(i; fooCollection)
{
...
}
}
`
The idea being that bar can be packed in a library and the
program that includes this library can decide what paramet
On Sunday, 2 December 2018 at 09:17:59 UTC, Domain wrote:
How to do that?
As far as I know dub does not support nested sub packages. You
could create a second dub package B with sub package B1 and
reference it from your sub package A1.
Kind regards
Andre
How to do that?
10 matches
Mail list logo