On Saturday, 3 August 2019 at 09:26:03 UTC, Andrey wrote:
Hello, how to get name of my application (project) that we
write in dub.json? Is there any compile-time constant like
__MODULE__?
If I understand the question correctly, you are looking for
std.file.thisExePath:
-
On Fri, 2019-08-02 at 16:49 +, Alexandre via Digitalmars-d-learn wrote:
[…]
>
> Do you thing D would be the right tool for the job at this point
> for me? Assuming I have 2 goals in mind: 1) become a better
> programmer and 2) want to make fun writing software for myself
> and if possible
On Fri, 2019-08-02 at 23:24 -0600, Jonathan M Davis via Digitalmars-d-learn
wrote:
[…]
> The university I went to had an undergrad class on programming paradigms
> that I _think_ was required (maybe two even), but it was definitely just the
> focus of a small number of classes, whereas my
On Friday, 2 August 2019 at 23:13:10 UTC, realhet wrote:
Today I read the documentation about structs, unions and
classes, but I haven't find any restrictions for the ~this()
destructors.
Is there some extra rules regarding the GC and what I must not
do in the destructors?
Class
On Fri, 2019-08-02 at 20:24 +, Jon Degenhardt via Digitalmars-d-learn
wrote:
[…]
> In my view, the most important thing is the decision you've
> already made - to pick a programming language and learn it in a
> reasonable bit of depth. Which programming language you choose is
> less
Hello, how to get name of my application (project) that we write
in dub.json? Is there any compile-time constant like __MODULE__?
On Saturday, 3 August 2019 at 05:33:05 UTC, Jonathan M Davis
wrote:
On Friday, August 2, 2019 5:13:10 PM MDT realhet via
Digitalmars-d-learn wrote:
Hi,
...
Thank you!
Now I have 2 solutions in mind:
1. If I only want to track the count and totalBytes for a
specific kind of reference, I will
On Fri, 2019-08-02 at 17:25 +, berni via Digitalmars-d-learn wrote:
> […]
>
> Yes, that was intentional. What I wanted to say is, that I think,
> that it would have been better, if C was never invented at all...
> In that case, there would have been space for an other language
> for
Thank you very much to Everybody!
Giovanni
On 8/3/19 5:26 AM, Andrey wrote:
Hello, how to get name of my application (project) that we write in
dub.json? Is there any compile-time constant like __MODULE__?
Dear Andrey:
Perhaps this is similar to what you are looking for:
https://dlang.org/spec/grammar.html#SpecialKeyword
Hi to everybody
I am doing some experiments about random numbers.
I need "extreme speed" for the generation for numbers from 1 to 8.
Generating 500_000_000 numbers with this code:
-
import std.stdio, std.array, std.random;
void main()
{
byte c;
Perhaps I posted this to the wrong forum.
Help needed.
https://forum.dlang.org/post/pdqfquklkhambfccg...@forum.dlang.org
The out-of-the box unittest runner is pretty bare by design. It
just runs unittest blocks in serial as functions where assert()
failures are not undefined behavior. Assert messages are not very
helpful, though the recently added flag `-checkaction=context`
helps a lot.
Luckily there is a
On Saturday, 3 August 2019 at 17:17:23 UTC, Cym13 wrote:
On Saturday, 3 August 2019 at 16:35:34 UTC, Giovanni Di Maria
wrote:
[...]
To what extent isn't the quality of randomness important to you?
Your posts reminds me of the way Doom (the original) did it for
things like enemy behaviour
On Saturday, 3 August 2019 at 17:44:44 UTC, lithium iodate wrote:
On Saturday, 3 August 2019 at 16:35:34 UTC, Giovanni Di Maria
wrote:
[...]
First off you could try to use a faster RNG engine than the
default. The easiest way is to define a variable containing it
and passing it to the
03.08.2019 12:26, Andrey пишет:
Hello, how to get name of my application (project) that we write in
dub.json? Is there any compile-time constant like __MODULE__?
You can get it using $DUB_PACKAGE from Environment variables
(https://dub.pm/package-format-sdl), for example using
On Friday, 2 August 2019 at 18:25:28 UTC, jmh530 wrote:
When I navigate to https://forum.dlang.org/ I have a message
that says "1 new reply" to "your posts." Normally, I click on
that "1 new reply" and find the post that's new, go to it, and
the message disappears. However, it doesn't seem to
On Saturday, 3 August 2019 at 16:35:34 UTC, Giovanni Di Maria
wrote:
Do you know other faster functions or methods to generate
random numbers?
For me the "goodness of random" is NOT important.
I found some nice random functions in this public-domain C
single-header library collection, one
Is it possible to somehow customize syntax and running of unit
tests?
How I could use it:
1. Running only the tests from recently modified source files.
2. Ability to add optional timeout constraint into the tests, and
then check whether the test doesn't exceed it.
unittests (time <
On Saturday, August 3, 2019 5:47:33 AM MDT Rémy Mouëza via Digitalmars-d-
learn wrote:
> On Saturday, 3 August 2019 at 09:26:03 UTC, Andrey wrote:
> > Hello, how to get name of my application (project) that we
> > write in dub.json? Is there any compile-time constant like
> > __MODULE__?
>
> If I
On Saturday, 3 August 2019 at 09:26:03 UTC, Andrey wrote:
Hello, how to get name of my application (project) that we
write in dub.json? Is there any compile-time constant like
__MODULE__?
The name of an application is not a compile time constant: you
can rename the executable at any time.
On Saturday, 3 August 2019 at 16:35:34 UTC, Giovanni Di Maria
wrote:
Hi to everybody
I am doing some experiments about random numbers.
I need "extreme speed" for the generation for numbers from 1 to
8.
Generating 500_000_000 numbers with this code:
-
import
On Saturday, 3 August 2019 at 16:35:34 UTC, Giovanni Di Maria
wrote:
Do you know other faster functions or methods to generate
random numbers?
For me the "goodness of random" is NOT important.
Thank you very much
GIovanni Di Maria
First off you could try to use a faster RNG engine than the
On Saturday, 3 August 2019 at 17:47:46 UTC, Giovanni Di Maria
wrote:
On Saturday, 3 August 2019 at 17:44:44 UTC, lithium iodate
wrote:
On Saturday, 3 August 2019 at 16:35:34 UTC, Giovanni Di Maria
wrote:
[...]
First off you could try to use a faster RNG engine than the
default. The easiest
On Saturday, 3 August 2019 at 16:35:34 UTC, Giovanni Di Maria
wrote:
For me the "goodness of random" is NOT important.
If that's the case, you could roll your own RNG:
//DMD64 D Compiler 2.072.2
import std.stdio;
import std.datetime;
import std.array, std.random;
void main(){
ubyte x;
25 matches
Mail list logo