February 09, 2023 General » Re: Weird DIP1000 issue | |||
|---|---|---|---|
| |||
...n % 2 == 1)) {
assert(o < odds.length);
assert(n == odds[o]);
++o;
}
assert(o == odds... | |||
February 08, 2023 Learn » Re: Comparison of multidimensional associative arrays | |||
|---|---|---|---|
| |||
...diff = difference(b, a);
import std.format;
assert(diff == expected, format!"UNEXPECTED: %s"(diff));
}
Ali
| |||
February 08, 2023 General » Re: Weird DIP1000 issue | |||
|---|---|---|---|
| |||
...x";
assert(b.m == "x");
b.m = a.m;
assert(b.m == "y");
static assert... | |||
February 07, 2023 Learn » Re: Default arguments | |||
|---|---|---|---|
| |||
...main()
{
auto bar = Sarr!()(dlang.dup); // complied
assert(is(typeof(bar.arr[0]) == char));
}
```
😀... | |||
February 07, 2023 Issues » [Issue 23679] New: 2147483647 does not exceed 0x7fffffff | |||
|---|---|---|---|
| |||
...sizlim.d
unittest {
ubyte [0x7fff_ffffU] arr;
assert (true);
}
$ dmd -unittest -main -run sizlim.d... | |||
February 07, 2023 Issues » [Issue 23678] New: Contracts are compiled with release switch? | |||
|---|---|---|---|
| |||
...chalucha@gmail.com
Test case:
```D
version (assert) int foo;
void test()
in (!foo)
{}
void... | |||
February 07, 2023 Learn » Default arguments | |||
|---|---|---|---|
| |||
...arr); assert(len2.length == 2); auto len4 = Sarr!short(addAndReturn(arr)); // add 'f' assert(len4... | |||
February 06, 2023 Issues » [Issue 23674] New: incompatible types for array comparison: string and string | |||
|---|---|---|---|
| |||
...element type.
---
void main()
{
string[2] arr;
assert(arr[2] == string.init);
}
---
onlineapp.d(4... | |||
February 06, 2023 Learn » Re: staticMap but with two arguments | |||
|---|---|---|---|
| |||
...0 .. $ / 2];
alias seconds = args[$ / 2 .. $];
static assert(firsts.length == seconds.length,
"Mismatched number of... | |||
February 06, 2023 Learn » Re: compile: link dynamic OR static library in Windows | |||
|---|---|---|---|
| |||
...writeln("start");
PGconn* conn = PQconnectdb("connection string");
assert(conn !is null);
PQfinish(conn);
writeln("end... | |||
Copyright © 1999-2021 by the D Language Foundation