On 2019-02-24 23:51, 0x wrote:
How to disable dub from checking internet before building, it's slowing
down build whenever it does this.
I thought that was fixed [1]. Or is it doing something else?
[1] https://dlang.org/changelog/2.082.0.html#upgrade_check
--
/Jacob Carlborg
I want to create a mixin with an arbitrary number of parameters.
I tried this:
mixin template ProviderParams(Types...)(Types t) {
}
But it does not compile. What's my error?
Can string mixing be split into several parts?
I have a mixin like this:
mixin("struct " ~ name ~ " {\n" ~
" struct Regular {\n" ~
"// ..." ~
" }\n" ~
" struct WithDefaults {\n" ~
"// ..." ~
" }\n" ~
'}');
I
On Monday, 25 February 2019 at 18:54:03 UTC, Jacob Carlborg wrote:
On 2019-02-24 23:51, 0x wrote:
How to disable dub from checking internet before building,
it's slowing down build whenever it does this.
I thought that was fixed [1]. Or is it doing something else?
[1]
On Monday, 25 February 2019 at 20:57:37 UTC, Victor Porton wrote:
Can string mixing be split into several parts?
I have a mixin like this:
mixin("struct " ~ name ~ " {\n" ~
" struct Regular {\n" ~
"// ..." ~
" }\n" ~
" struct WithDefaults {\n"
Hi,
I am using the Arsd cgi class
(https://github.com/adamdruppe/arsd) to spawn an http server.
Each http request is handled in its own thread. Is it safe to set
in void main a FileLogger to which each thread will write to?
void main()
{
...
sharedLog = new
On Mon, Feb 25, 2019 at 08:23:10PM +, Victor Porton via Digitalmars-d-learn
wrote:
> I want to create a mixin with an arbitrary number of parameters.
>
> I tried this:
>
> mixin template ProviderParams(Types...)(Types t) {
> }
>
> But it does not compile. What's my error?
All you need is:
On Monday, 25 February 2019 at 06:51:20 UTC, Yevano wrote:
I am writing a domain specific language of sorts in D for the
lambda calculus. One of my requirements is that I should be
able to generate expressions like this:
new Abstraction(v1, M)
like this:
L!(x => M)
A word of caution: this
I want to create a string mixin based on a supplementary variable
(name2 below):
Let we have something like:
mixin template X(string name) {
immutable string name2 = '_' ~ name;
mixin("struct " ~ name2 ~ "{ int i; }");
}
But it would create variable name2 inside X, which should not be
I need help with the arsd.simpledisplay module. Is there anyone
there who knows about it? I have doubts concerning
SimpleWindow.eventLoop().
On Monday, February 25, 2019 5:07:54 PM MST Victor Porton via Digitalmars-d-
learn wrote:
> I want to create a string mixin based on a supplementary variable
> (name2 below):
>
> Let we have something like:
>
> mixin template X(string name) {
>immutable string name2 = '_' ~ name;
>
On Tuesday, 26 February 2019 at 00:07:54 UTC, Victor Porton wrote:
I want to create a string mixin based on a supplementary
variable (name2 below):
Let we have something like:
mixin template X(string name) {
immutable string name2 = '_' ~ name;
mixin("struct " ~ name2 ~ "{ int i; }");
}
On Tuesday, 26 February 2019 at 00:07:54 UTC, Victor Porton wrote:
I want to create a string mixin based on a supplementary
variable (name2 below):
Let we have something like:
mixin template X(string name) {
immutable string name2 = '_' ~ name;
mixin("struct " ~ name2 ~ "{ int i; }");
}
On Tuesday, 12 February 2019 at 01:31:48 UTC, Adam D. Ruppe wrote:
On Tuesday, 12 February 2019 at 01:16:21 UTC, Murilo wrote:
Hi Adam. I have been using your arsd library and I have
noticed that compiling with -m64 causes this error:
huh, only on 64 bit windows.
well, pushed a fix up, try
On Monday, 25 February 2019 at 22:34:54 UTC, Murilo wrote:
Hi Adam. I am using your library. There is the ScreenPainter
struct and it has a method called .eventLoop(), how do I make
it stop after a certain amount of loops? I would like to be
able to call it several times in the program.
I
On Tuesday, 26 February 2019 at 04:17:04 UTC, Michelle Long wrote:
e.g., using sdl for different versions and have it
automatically switch.
What would be nice is if one could stick all the files for x86
in one dir and x64 in the others and they will be used
depending on the build(and copied)
On 2/25/19 2:09 AM, Nicholas Wilson wrote:
Leaving aside the issue of why DMD can't handle this, the entire reason
pragma(inline, bool) takes a bool is for it to be (potentially)
predicated.
In this case you want:
version(DigitalMars)
private enum inline_overlaps = false;
else //
On Monday, 25 February 2019 at 23:35:24 UTC, Murilo wrote:
I need help with the arsd.simpledisplay module. Is there anyone
there who knows about it? I have doubts concerning
SimpleWindow.eventLoop().
I'm pretty sure Adam D. Ruppe knows about it since he's the
author :)
What exactly is the
On Tuesday, 26 February 2019 at 04:20:27 UTC, Michelle Long wrote:
On Tuesday, 26 February 2019 at 04:17:04 UTC, Michelle Long
wrote:
e.g., using sdl for different versions and have it
automatically switch.
What would be nice is if one could stick all the files for x86
in one dir and x64 in
On 2/25/19 2:09 AM, Nicholas Wilson wrote:
Leaving aside the issue of why DMD can't handle this, the entire reason
pragma(inline, bool) takes a bool is for it to be (potentially) predicated.
In this case you want:
version(DigitalMars)
private enum inline_overlaps = false;
else // assuming
On Monday, February 25, 2019 9:17:04 PM MST Michelle Long via Digitalmars-d-
learn wrote:
> e.g., using sdl for different versions and have it automatically
> switch.
>
> What would be nice is if one could stick all the files for x86 in
> one dir and x64 in the others and they will be used
e.g., using sdl for different versions and have it automatically
switch.
What would be nice is if one could stick all the files for x86 in
one dir and x64 in the others and they will be used depending on
the build(and copied)
Ideally one can do it for debug and release versions too.
One thing. The variables were reversed. Fixed by changing these
lines.
auto result = new Abstraction(vars[$ - 1], f(vars));
foreach_reverse(e; vars[0..$ - 1]) {
result = new Abstraction(e, result);
}
On Monday, 25 February 2019 at 07:40:51 UTC, Simen Kjærås wrote:
The simple scalable version - just change maxArgs to a number
that suits you:
It works! Thanks. Didn't know about static foreach.
On Monday, 25 February 2019 at 08:24:06 UTC, Yevano wrote:
One thing. The variables were reversed. Fixed by changing these
lines.
auto result = new Abstraction(vars[$ - 1], f(vars));
foreach_reverse(e; vars[0..$ - 1]) {
result = new Abstraction(e, result);
}
Yup. I assumed that didn't
On Sunday, 24 February 2019 at 11:05:31 UTC, Alex wrote:
On Sunday, 24 February 2019 at 10:53:09 UTC, aliak wrote:
[...]
There is a semantic difference between a switch and a final
switch statement, defined here:
https://dlang.org/spec/statement.html#final-switch-statement
By this
Hello.
I wish to sort an array by calling a template function on a
struct. In essence I want to do
foos.sort!("a.get!Dummy < b.get!Dummy");
but I get the error message
/dlang/dmd/linux/bin64/../../src/phobos/std/functional.d-mixin-215(215): Error: undefined identifier Dummy
Is
On Monday, 25 February 2019 at 12:37:31 UTC, Vladimirs Nordholm
wrote:
Hello.
I wish to sort an array by calling a template function on a
struct. In essence I want to do
foos.sort!("a.get!Dummy < b.get!Dummy");
but I get the error message
On Monday, 25 February 2019 at 12:37:31 UTC, Vladimirs Nordholm
wrote:
Hello.
I wish to sort an array by calling a template function on a
struct. In essence I want to do
foos.sort!("a.get!Dummy < b.get!Dummy");
but I get the error message
On Monday, 25 February 2019 at 12:47:50 UTC, Andrea Fontana wrote:
On Monday, 25 February 2019 at 12:37:31 UTC, Vladimirs Nordholm
wrote:
Hello.
I wish to sort an array by calling a template function on a
struct. In essence I want to do
foos.sort!("a.get!Dummy < b.get!Dummy");
but I
On Monday, 25 February 2019 at 12:47:47 UTC, Simen Kjærås wrote:
On Monday, 25 February 2019 at 12:37:31 UTC, Vladimirs Nordholm
wrote:
Hello.
I wish to sort an array by calling a template function on a
struct. In essence I want to do
foos.sort!("a.get!Dummy < b.get!Dummy");
but I get
On Monday, 25 February 2019 at 06:29:14 UTC, drug wrote:
On 25.02.2019 1:51, 0x wrote:
How to disable dub from checking internet before building,
it's slowing down build whenever it does this.
`--skip-registry=all` let you avoid checking of all
dependencies (https://dub.pm/commandline)
On Monday, February 25, 2019 5:47:47 AM MST Simen Kjærås via Digitalmars-d-
learn wrote:
> On Monday, 25 February 2019 at 12:37:31 UTC, Vladimirs Nordholm
>
> wrote:
> > Hello.
> >
> > I wish to sort an array by calling a template function on a
> > struct. In essence I want to do
> >
> >
33 matches
Mail list logo