D's compile-time-execution is fantastic, but there are some times
when I'd like to examine the generated code, or produce code that
needs to pass through earlier phases before CTFE, or do AST
stuff. Sometimes I simply don't want to generate the code with
every compilation, so saving the generat
On Tuesday, 4 August 2020 at 19:52:47 UTC, Andy Balba wrote:
i.e. D equivalent to C++ command system("MyExe")
Apart from std.process, you can also call the C function in D
after importing core.stdc.stdlib:
https://dlang.org/library/core/stdc/stdlib/system.html
On Sunday, 2 August 2020 at 19:19:51 UTC, Andy Balba wrote:
On Sunday, 2 August 2020 at 06:37:06 UTC, tastyminerals wrote:
You haven't said anything about efficiency because if you care
and your arrays are rather big, you better go with
https://github.com/libmir/mir-algorithm as mentioned abov
On Tuesday, 4 August 2020 at 19:52:47 UTC, Andy Balba wrote:
i.e. D equivalent to C++ command system("MyExe")
https://dlang.org/library/std/process.html
i.e. D equivalent to C++ command system("MyExe")
On Tuesday, 4 August 2020 at 17:49:56 UTC, drathier wrote:
Replaced all mentions of uint64_t with ulong, and now it works.
Must have an enum called uint64_t defined somewhere in a
library I depend on or something? Really wish this was clearer.
BTW I believe the reason that `uint64_t` is an enu
On 8/4/20 2:15 PM, Steven Schveighoffer wrote:
I'll file a bug.
https://issues.dlang.org/show_bug.cgi?id=21112
-Steve
On 8/4/20 1:36 PM, drathier wrote:
I'm getting a crash when I'm converting a double to an uint64_t.
```
std.conv.ConvException@/usr/local/opt/dmd/include/dlang/dmd/std/conv.d(2054):
Value (1596) does not match any member value of enum '__c_ulonglong'
```
I've narrowed down the code to this:
`
Replaced all mentions of uint64_t with ulong, and now it works.
Must have an enum called uint64_t defined somewhere in a library
I depend on or something? Really wish this was clearer.
On Tuesday, 4 August 2020 at 17:37:56 UTC, drathier wrote:
```
std.conv.ConvException@/usr/local/opt/dmd/include/dlang/dmd/std/conv.d(2054):
Value (1596) does not match any member value of enum '__c_ulonglong'
```
well,
```
std.conv.ConvException@/usr/local/opt/dmd/include/dlang/dmd/std/conv.d(
```
std.conv.ConvException@/usr/local/opt/dmd/include/dlang/dmd/std/conv.d(2054):
Value (1596) does not match any member value of enum '__c_ulonglong'
```
well,
```
std.conv.ConvException@/usr/local/opt/dmd/include/dlang/dmd/std/conv.d(2054):
Value (42) does not match any member value of enum '
On Saturday, 1 August 2020 at 23:08:38 UTC, Chad Joan wrote:
Though if the compiler is allowed to split a single uint64_t
into two registers, I would expect it to split struct/string
into two registers as well. At least, the manual doesn't seem
to explicitly mention higher-level constructs like
I'm getting a crash when I'm converting a double to an uint64_t.
```
std.conv.ConvException@/usr/local/opt/dmd/include/dlang/dmd/std/conv.d(2054):
Value (1596) does not match any member value of enum '__c_ulonglong'
```
I've narrowed down the code to this:
```
static import std.conv;
double thi
On 8/4/20 9:39 AM, Adam D. Ruppe wrote:
On Tuesday, 4 August 2020 at 13:36:15 UTC, Zans wrote:
Is there any way to declare template functions inside interface and
then override them in a class?
No, the templates in the interface are automatically considered `final`.
So the body must be in the
On Monday, 3 August 2020 at 19:42:51 UTC, Steven Schveighoffer
wrote:
On 8/3/20 3:22 PM, Bruce Carneal wrote:
Thanks Steve (and Chad). Summary: underspecified, varying
behavior across versions, buggy.
Steve, what's the best way for me to report this? Are spec
issues lumped in with the oth
On Tuesday, 4 August 2020 at 13:36:15 UTC, Zans wrote:
Is there any way to declare template functions inside interface
and then override them in a class?
No, the templates in the interface are automatically considered
`final`. So the body must be in the interface too to avoid that
undefined r
Is there any way to declare template functions inside interface
and then override them in a class?
Trying to compile the following code results in "undefined
reference" error:
import std.stdio;
interface MyInterface
{
T doAndReturnSomething(T)(T param);
}
class MyClass : MyInterface
{
17 matches
Mail list logo