D officially supported on Apache NuttX RTOS

2024-06-07 Thread Matheus Catarino via Digitalmars-d-announce
ref.: https://x.com/MisterTechBlog/status/1798918878350950840 **Note:** Currently, ldc2 compiler only for riscv/arm/sim[ulator]. gdc and dmd need PR! **Preview - qemu-armv7a:nsh** ```bash $ qemu-system-arm -cpu cortex-a7 -nographic -M virt,virtualization=off,gic-version=2 -net none -chardev

[Issue 10376] Mutable field initializer reference is accessible through immutable aggregate

2024-06-07 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=10376 Nick Treleaven changed: What|Removed |Added CC||john.loughran.colvin@gmail.

[Issue 15612] Break immutability with default initialisers

2024-06-07 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=15612 Nick Treleaven changed: What|Removed |Added Status|NEW |RESOLVED CC|

[Issue 24587] Allow negated qualifiers in cast expressions

2024-06-07 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=24587 RazvanN changed: What|Removed |Added CC||razvan.nitu1...@gmail.com --- Comment #1 from

Re: Unintentional sharing?

2024-06-06 Thread H. S. Teoh via Digitalmars-d-learn
On Thu, Jun 06, 2024 at 05:49:39PM +, Andy Valencia via Digitalmars-d-learn wrote: > I was using instance initialization which allocated a new object. My > intention was this initialization would happen per-instance, but all > instances appear to share the same sub-object? That

Re: Unintentional sharing?

2024-06-06 Thread Nick Treleaven via Digitalmars-d-learn
On Thursday, 6 June 2024 at 17:49:39 UTC, Andy Valencia wrote: I was using instance initialization which allocated a new object. My intention was this initialization would happen per-instance, but all instances appear to share the same sub-object? That is, f1.b and f2.b appear to point to a

[Issue 10376] Mutable field initializer reference is accessible through immutable aggregate

2024-06-06 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=10376 Nick Treleaven changed: What|Removed |Added See Also||https://issues.dlang.org/sh

[Issue 2947] Static initializer stored in mutable non-TLS global

2024-06-06 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=2947 Nick Treleaven changed: What|Removed |Added CC||n...@geany.org See Also|

Re: Unintentional sharing?

2024-06-06 Thread evilrat via Digitalmars-d-learn
On Thursday, 6 June 2024 at 17:49:39 UTC, Andy Valencia wrote: I was using instance initialization which allocated a new object. My intention was this initialization would happen per-instance, but all instances appear to share the same sub-object? That is, f1.b and f2.b appear to point to a

Unintentional sharing?

2024-06-06 Thread Andy Valencia via Digitalmars-d-learn
I was using instance initialization which allocated a new object. My intention was this initialization would happen per-instance, but all instances appear to share the same sub-object? That is, f1.b and f2.b appear to point to a single object? Obviously I moved the new into the initializer

Re: How to pass in reference a fixed array in parameter

2024-06-06 Thread Quirin Schroll via Digitalmars-d-learn
On Tuesday, 4 June 2024 at 12:22:23 UTC, Eric P626 wrote: I am currently trying to learn how to program in D. I thought that I could start by trying some maze generation algorithms. I have a maze stored as 2D array of structure defined as follow which keep tracks of wall positions: ~~~

Re: bool passed by ref, safe or not ?

2024-06-06 Thread Quirin Schroll via Digitalmars-d-learn
On Wednesday, 5 June 2024 at 18:31:12 UTC, Basile B. wrote: On Wednesday, 5 June 2024 at 01:18:06 UTC, Paul Backus wrote: On Tuesday, 4 June 2024 at 16:58:50 UTC, Basile B. wrote: ```d void main(string[] args) { ushort a = 0b; bool* b = cast(bool*) setIt(*b);

[Issue 24588] Buy Psilocybin Magic Mushrooms

2024-06-06 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=24588 RazvanN changed: What|Removed |Added Status|NEW |RESOLVED CC|

Re: How to pass in reference a fixed array in parameter

2024-06-06 Thread Eric P626 via Digitalmars-d-learn
On Wednesday, 5 June 2024 at 10:36:50 UTC, Nick Treleaven wrote: ```d import std.stdio; alias s_cell = int; void main() { writeln("Maze generation demo"); s_cell [5][5] maze; int n; foreach (i, row; maze) foreach (j, col; row) maze[i][j] = n++; s_cell[][5]

[Issue 24589] New: [std.sreaching] take functions seem to be missing range overload/version

2024-06-05 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=24589 Issue ID: 24589 Summary: [std.sreaching] take functions seem to be missing range overload/version Product: D Version: D2 Hardware: All URL:

Re: bool passed by ref, safe or not ?

2024-06-05 Thread Basile B. via Digitalmars-d-learn
On Wednesday, 5 June 2024 at 01:18:06 UTC, Paul Backus wrote: On Tuesday, 4 June 2024 at 16:58:50 UTC, Basile B. wrote: ```d void main(string[] args) { ushort a = 0b; bool* b = cast(bool*) setIt(*b); assert(a == 0b); // what actually happens

Re: How to pass in reference a fixed array in parameter

2024-06-05 Thread bauss via Digitalmars-d-learn
On Wednesday, 5 June 2024 at 06:22:34 UTC, Eric P626 wrote: I tried the following signatures with the ref keyword and it did not change anything: ~~~ void print_maze ( ref s_cell maze ) void print_maze ( ref s_cell [][] maze ) ~~~ From what I found, arrays passed in parameters are always

[Issue 24588] Buy Psilocybin Magic Mushrooms

2024-06-05 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=24588 veronapressbuymagicmushrooms changed: What|Removed |Added URL||http://www.veronapress.com/

[Issue 20010] allow cast of type, not only expressions

2024-06-05 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=20010 Bolpat changed: What|Removed |Added CC||qs.il.paperi...@gmail.com --- Comment #1 from

[Issue 24587] New: Allow negated qualifiers in cast expressions

2024-06-05 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=24587 Issue ID: 24587 Summary: Allow negated qualifiers in cast expressions Product: D Version: D2 Hardware: All OS: All Status: NEW Severity: enhancement

Re: How to pass in reference a fixed array in parameter

2024-06-05 Thread evilrat via Digitalmars-d-learn
On Wednesday, 5 June 2024 at 11:27:32 UTC, Nick Treleaven wrote: On Wednesday, 5 June 2024 at 09:24:23 UTC, evilrat wrote: for simple cases like this it might work, but 2d array is not even contiguous, A 2D static array is contiguous: https://dlang.org/spec/arrays.html#rectangular-arrays D

Re: How to pass in reference a fixed array in parameter

2024-06-05 Thread Nick Treleaven via Digitalmars-d-learn
On Wednesday, 5 June 2024 at 09:24:23 UTC, evilrat wrote: for simple cases like this it might work, but 2d array is not even contiguous, A 2D static array is contiguous: https://dlang.org/spec/arrays.html#rectangular-arrays D static arrays, while using the same syntax, are implemented as a

[Issue 24582] Detect unsafe `cast(bool[])`

2024-06-05 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=24582 Nick Treleaven changed: What|Removed |Added See Also||https://issues.dlang.org/sh

[Issue 20148] void initializated bool can be both true and false

2024-06-05 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=20148 Nick Treleaven changed: What|Removed |Added See Also||https://issues.dlang.org/sh

Re: How to pass in reference a fixed array in parameter

2024-06-05 Thread Nick Treleaven via Digitalmars-d-learn
On Wednesday, 5 June 2024 at 10:27:47 UTC, Nick Treleaven wrote: foreach (i, row; maze) slices[i] = row; Sorry that assignment was wrong (edited at last minute). Fixed: ```d import std.stdio; alias s_cell = int; void main() { writeln("Maze generation demo"); s_cell [5][5]

Re: How to pass in reference a fixed array in parameter

2024-06-05 Thread Nick Treleaven via Digitalmars-d-learn
On Wednesday, 5 June 2024 at 10:27:47 UTC, Nick Treleaven wrote: //~ void print_maze ( s_cell [][] maze... ) I meant to delete that line!

Re: How to pass in reference a fixed array in parameter

2024-06-05 Thread Nick Treleaven via Digitalmars-d-learn
On Tuesday, 4 June 2024 at 12:22:23 UTC, Eric P626 wrote: ~~~ void main() { writeln("Maze generation demo"); s_cell [5][5] maze; print_maze (maze); } void print_maze ( s_cell [][] maze ) { } ~~~ This is how to do it without GC allocations (I have used `int` instead for demo

Re: How to pass in reference a fixed array in parameter

2024-06-05 Thread Kagamin via Digitalmars-d-learn
With accessor: ``` void main() { s_cell[] maze=make(5,5); s_cell a=maze.get(1,2); print_maze(maze); } void print_maze(s_cell[] maze) { } s_cell[] make(int width, int height) { return new s_cell[width*height]; } s_cell get(s_cell[] maze, int x, int y) { return maze[5*y+x];

Re: How to pass in reference a fixed array in parameter

2024-06-05 Thread Nick Treleaven via Digitalmars-d-learn
On Wednesday, 5 June 2024 at 06:22:34 UTC, Eric P626 wrote: Now according to the book, it's possible to assign a slice from a fixed array. This code will compile: ~~~ int[12] monthDays = [ 31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31 ]; int[] a_slice = monthDays; ~~~ The element types

Re: How to pass in reference a fixed array in parameter

2024-06-05 Thread Kagamin via Digitalmars-d-learn
On Tuesday, 4 June 2024 at 12:22:23 UTC, Eric P626 wrote: I try to create a 2D array of fixed length and pass it in parameter as a reference. Normally, in C, I would have used a pointer as parameter, and pass the address of the array. Not obvious what you're trying to do. How would you do it

Re: How to pass in reference a fixed array in parameter

2024-06-05 Thread evilrat via Digitalmars-d-learn
On Wednesday, 5 June 2024 at 06:22:34 UTC, Eric P626 wrote: On Tuesday, 4 June 2024 at 16:19:39 UTC, Andy Valencia wrote: On Tuesday, 4 June 2024 at 12:22:23 UTC, Eric P626 wrote: Thanks for the comments. So far, I only managed to make it work by creating a dynamic array and keeping the same

Re: bool passed by ref, safe or not ?

2024-06-05 Thread Nick Treleaven via Digitalmars-d-learn
On Wednesday, 5 June 2024 at 09:09:40 UTC, Kagamin wrote: On Wednesday, 5 June 2024 at 01:18:06 UTC, Paul Backus wrote: The only safe values for a `bool` are 0 (false) and 1 (true). AFAIK that was fixed and now full 8-bit range is safe. `cast(bool) someByte` is fine - that doesn't

Re: bool passed by ref, safe or not ?

2024-06-05 Thread Kagamin via Digitalmars-d-learn
On Wednesday, 5 June 2024 at 01:18:06 UTC, Paul Backus wrote: The only safe values for a `bool` are 0 (false) and 1 (true). AFAIK that was fixed and now full 8-bit range is safe.

Re: bool passed by ref, safe or not ?

2024-06-05 Thread Dukc via Digitalmars-d-learn
Basile B. kirjoitti 4.6.2024 klo 19.58: I understand that the notion of `bool` doesn't exist on X86, hence what will be used is rather an instruction that write on the lower 8 bits, but with a 7 bits corruption. Do I corrupt memory here or not ? Is that a safety violation ? Viewing a valid

Re: How to pass in reference a fixed array in parameter

2024-06-05 Thread Eric P626 via Digitalmars-d-learn
On Tuesday, 4 June 2024 at 16:19:39 UTC, Andy Valencia wrote: On Tuesday, 4 June 2024 at 12:22:23 UTC, Eric P626 wrote: I tried to find a solution on the internet, but could not find anything, I stumble a lot on threads about Go or Rust language even if I specify "d language" in my search.

Re: bool passed by ref, safe or not ?

2024-06-04 Thread Olivier Pisano via Digitalmars-d-learn
On Wednesday, 5 June 2024 at 05:15:42 UTC, Olivier Pisano wrote: This is technically not a memory corruption, because as bool.sizeof < int.sizeof, you just write the low order byte of an int you allocated on the stack. It was not an int, it was a ushort. Anyway, what I wrote still applies.

Re: bool passed by ref, safe or not ?

2024-06-04 Thread Olivier Pisano via Digitalmars-d-learn
On Tuesday, 4 June 2024 at 16:58:50 UTC, Basile B. wrote: question in the header, code in the body, execute on a X86 or X86_64 CPU I understand that the notion of `bool` doesn't exist on X86, hence what will be used is rather an instruction that write on the lower 8 bits, but with a 7 bits

Re: bool passed by ref, safe or not ?

2024-06-04 Thread Basile B. via Digitalmars-d-learn
On Wednesday, 5 June 2024 at 01:18:06 UTC, Paul Backus wrote: On Tuesday, 4 June 2024 at 16:58:50 UTC, Basile B. wrote: you have violated the language's safety invariants. ah mais non.

[Issue 24586] New: [REG 2.108] initialization of immutable arrays with a system function marks the array as system

2024-06-04 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=24586 Issue ID: 24586 Summary: [REG 2.108] initialization of immutable arrays with a system function marks the array as system Product: D Version: D2 Hardware: All OS:

Re: bool passed by ref, safe or not ?

2024-06-04 Thread Paul Backus via Digitalmars-d-learn
On Tuesday, 4 June 2024 at 16:58:50 UTC, Basile B. wrote: ```d void main(string[] args) { ushort a = 0b; bool* b = cast(bool*) setIt(*b); assert(a == 0b); // what actually happens assert(a == 0b1110); // what would be safe } ```

Re: bool passed by ref, safe or not ?

2024-06-04 Thread Steven Schveighoffer via Digitalmars-d-learn
On Tuesday, 4 June 2024 at 16:58:50 UTC, Basile B. wrote: question in the header, code in the body, execute on a X86 or X86_64 CPU ```d module test; void setIt(ref bool b) @safe { b = false; } void main(string[] args) { ushort a = 0b; bool* b = cast(bool*)

Re: bool passed by ref, safe or not ?

2024-06-04 Thread rkompass via Digitalmars-d-learn
On Tuesday, 4 June 2024 at 16:58:50 UTC, Basile B. wrote: question in the header, code in the body, execute on a X86 or X86_64 CPU ```d module test; void setIt(ref bool b) @safe { b = false; } void main(string[] args) { ushort a = 0b; bool* b = cast(bool*)

bool passed by ref, safe or not ?

2024-06-04 Thread Basile B. via Digitalmars-d-learn
question in the header, code in the body, execute on a X86 or X86_64 CPU ```d module test; void setIt(ref bool b) @safe { b = false; } void main(string[] args) { ushort a = 0b; bool* b = cast(bool*) setIt(*b); assert(a == 0b); // what

Re: How to pass in reference a fixed array in parameter

2024-06-04 Thread Andy Valencia via Digitalmars-d-learn
On Tuesday, 4 June 2024 at 12:22:23 UTC, Eric P626 wrote: I tried to find a solution on the internet, but could not find anything, I stumble a lot on threads about Go or Rust language even if I specify "d language" in my search. Aside from the excellent answer already present, I wanted to

Re: How to pass in reference a fixed array in parameter

2024-06-04 Thread evilrat via Digitalmars-d-learn
On Tuesday, 4 June 2024 at 12:22:23 UTC, Eric P626 wrote: I am currently trying to learn how to program in D. I thought that I could start by trying some maze generation algorithms. I have a maze stored as 2D array of structure defined as follow which keep tracks of wall positions: ~~~

How to pass in reference a fixed array in parameter

2024-06-04 Thread Eric P626 via Digitalmars-d-learn
I am currently trying to learn how to program in D. I thought that I could start by trying some maze generation algorithms. I have a maze stored as 2D array of structure defined as follow which keep tracks of wall positions: ~~~ struct s_cell { bool north = true; bool east = true;

[Issue 24585] Allow switch with multiple arguments

2024-06-04 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=24585 Bolpat changed: What|Removed |Added Priority|P1 |P4 CC|

[Issue 24585] New: Allow switch with multiple arguments

2024-06-04 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=24585 Issue ID: 24585 Summary: Allow switch with multiple arguments Product: D Version: D2 Hardware: All OS: All Status: NEW Severity: enhancement

Re: need help to use C++ callback from garnet

2024-06-04 Thread Dakota via Digitalmars-d-learn
On Wednesday, 29 May 2024 at 09:01:13 UTC, evilrat wrote: On Wednesday, 29 May 2024 at 07:47:01 UTC, Dakota wrote: [...] (here is the signature of callback) https://github.com/microsoft/garnet/blob/ade2991f3737b9b5e3151d0dd0b614adfd4bcecd/libs/storage/Tsavorite/cc/src/device/async.h#L25

Re: LDC 1.39.0-beta1

2024-06-04 Thread Dakota via Digitalmars-d-announce
On Monday, 3 June 2024 at 19:42:42 UTC, kinke wrote: Glad to announce the first beta for LDC 1.39. Major changes: * Based on D 2.109.0. * LLVM for prebuilt packages bumped to v18.1.6. * Support for LLVM 11-14 was dropped. The CLI options `-passmanager` and `-opaque-pointers` were removed.

Re: Release D 2.109.0

2024-06-03 Thread Nick Treleaven via Digitalmars-d-announce
On Sunday, 2 June 2024 at 15:51:04 UTC, Iain Buclaw wrote: Glad to announce D 2.109.0, ♥ to the 44 contributors. This release comes with 15 major changes and 26 fixed Bugzilla issues, including: Thanks! I've written a changelog entry about reinterpreting a byte as bool being unsafe:

LDC 1.39.0-beta1

2024-06-03 Thread kinke via Digitalmars-d-announce
Glad to announce the first beta for LDC 1.39. Major changes: * Based on D 2.109.0. * LLVM for prebuilt packages bumped to v18.1.6. * Support for LLVM 11-14 was dropped. The CLI options `-passmanager` and `-opaque-pointers` were removed. Full release log and downloads:

[Issue 24582] Detect unsafe `cast(bool[])`

2024-06-03 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=24582 --- Comment #3 from Nick Treleaven --- bool v = cast(bool) 2; ubyte[] a = [2, 4]; auto b = cast(bool[]) a; auto c = cast(bool[]) [2, 4]; // literal cast import std.stdio; writeln(*cast(byte*)); // 1, OK

[Issue 24582] Detect unsafe `cast(bool[])`

2024-06-03 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=24582 Nick Treleaven changed: What|Removed |Added Summary|Detect unsafe casting to|Detect unsafe |bool

[Issue 20423] di generator does not emit nothrow on dtors

2024-06-03 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=20423 Richard (Rikki) Andrew Cattermole changed: What|Removed |Added CC||alphaglosi...@gmail.com

[Issue 24582] Detect unsafe casting to bool

2024-06-03 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=24582 Dennis changed: What|Removed |Added CC||dkor...@live.nl Hardware|x86_64

[Issue 24584] New: [phobos] `make unittest` should not rerun tests unnecessarily

2024-06-03 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=24584 Issue ID: 24584 Summary: [phobos] `make unittest` should not rerun tests unnecessarily Product: D Version: D2 Hardware: x86_64 OS: Linux Status: NEW

[Issue 3947] Implicit and explicit casting of floating point to bool produces different results

2024-06-03 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=3947 Nick Treleaven changed: What|Removed |Added CC||n...@geany.org --- Comment #1 from Nick

[Issue 24583] di generator emits return scope and scope return in wrong order

2024-06-03 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=24583 Richard (Rikki) Andrew Cattermole changed: What|Removed |Added Keywords||mangling, safe --

Re: DConf '24 Schedule & BeerConf News

2024-06-03 Thread Richard (Rikki) Andrew Cattermole via Digitalmars-d-announce
Very awesome lineup this year!

[Issue 24583] New: di generator emits return scope and scope return in wrong order

2024-06-03 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=24583 Issue ID: 24583 Summary: di generator emits return scope and scope return in wrong order Product: D Version: D2 Hardware: All OS: All Status: NEW

Re: DConf '24 Schedule & BeerConf News

2024-06-03 Thread FeepingCreature via Digitalmars-d-announce
On Monday, 3 June 2024 at 13:26:54 UTC, Mike Parker wrote: ## The DConf '24 Schedule The DConf '24 schedule is now live: https://dconf.org/2024/index.html#schedule You'll notice that we've departed from the norm in a few places. That's because of the number of submissions we received.

DConf '24 Schedule & BeerConf News

2024-06-03 Thread Mike Parker via Digitalmars-d-announce
## The DConf '24 Schedule The DConf '24 schedule is now live: https://dconf.org/2024/index.html#schedule You'll notice that we've departed from the norm in a few places. That's because of the number of submissions we received. Typically, we receive either just enough or many more than we

[Issue 24582] Detect unsafe casting to bool

2024-06-03 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=24582 Dlang Bot changed: What|Removed |Added Keywords||pull --- Comment #1 from Dlang Bot --- @ntrel

[Issue 24582] Detect unsafe casting to bool

2024-06-03 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=24582 Nick Treleaven changed: What|Removed |Added Keywords||safe --

[Issue 24582] New: Detect unsafe casting to bool

2024-06-03 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=24582 Issue ID: 24582 Summary: Detect unsafe casting to bool Product: D Version: D2 Hardware: x86_64 OS: Linux Status: NEW Severity: major Priority: P1

[Issue 24581] Add a @gc attribute already

2024-06-03 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=24581 Bolpat changed: What|Removed |Added CC||qs.il.paperi...@gmail.com --

[Issue 24581] New: Add a @gc attribute already

2024-06-03 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=24581 Issue ID: 24581 Summary: Add a @gc attribute already Product: D Version: D2 Hardware: All OS: All Status: NEW Severity: enhancement Priority: P1

[Issue 19916] union member access should be un-@safe

2024-06-03 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=19916 Nick Treleaven changed: What|Removed |Added CC||n...@geany.org --- Comment #24 from Nick

Re: How does one attach a manifest file to a D executable on Windows?

2024-06-02 Thread John Chapman via Digitalmars-d-learn
On Sunday, 2 June 2024 at 21:46:41 UTC, solidstate1991 wrote: Well, it turns out I used the windres found in mingw instead of `rc.exe` since the latter cannot be found anywhere on my PC, even after reinstalling stuff. I need to hunt it down somehow. rc.exe comes with the Windows SDK - it gets

Re: How does one attach a manifest file to a D executable on Windows?

2024-06-02 Thread solidstate1991 via Digitalmars-d-learn
On Sunday, 2 June 2024 at 19:11:10 UTC, solidstate1991 wrote: Added a few more line to my `resources.rc` file, it seems like the issue is the resource file not being touched at all. I've put `dflags "resources.res" platform="windows"` in my `dub.sdl` file, it doesn't even care if there's a

[Issue 24580] ImportC: Asm label after attributes results in syntax error

2024-06-02 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=24580 Tim changed: What|Removed |Added Keywords||ImportC --

[Issue 24580] New: ImportC: Asm label after attributes results in syntax error

2024-06-02 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=24580 Issue ID: 24580 Summary: ImportC: Asm label after attributes results in syntax error Product: D Version: D2 Hardware: x86_64 OS: Linux Status: NEW

Re: How does one attach a manifest file to a D executable on Windows?

2024-06-02 Thread solidstate1991 via Digitalmars-d-learn
On Saturday, 25 May 2024 at 19:51:25 UTC, John Chapman wrote: Not tested but from memory I do this: 1) Copy that first XML snippet from the page you linked, save to a file called example.exe.manifest 2) Create a resource script file called resources.rc, with this at the top: 1 24

Re: Socket and spawn()

2024-06-02 Thread Andy Valencia via Digitalmars-d-learn
On Sunday, 2 June 2024 at 17:46:09 UTC, bauss wrote: If anything you should use a thread pool that each handles a set of sockets, instead of each thread being a single socket. Yup, thread pool it is. I'm still fleshing out the data structure which manages the incoming work presented to the

Re: Socket and spawn()

2024-06-02 Thread bauss via Digitalmars-d-learn
On Friday, 31 May 2024 at 16:07:23 UTC, Andy Valencia wrote: I'm coding a server which takes TCP connections. I end up in the main thread with .accept() which hands me a Socket. I'd like to hand this off to a spawn()'ed thread to do the actual work. Aliases to mutable thread-local data

Release D 2.109.0

2024-06-02 Thread Iain Buclaw via Digitalmars-d-announce
Glad to announce D 2.109.0, ♥ to the 44 contributors. This release comes with 15 major changes and 26 fixed Bugzilla issues, including: - In the language, a new function `__ctfeWrite` has been added to allow writing messages from CTFE to console. - `__traits(isBitfeld)`, and the properties

[Issue 24579] New: stat_t has wrong size for Android armv7a

2024-06-02 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=24579 Issue ID: 24579 Summary: stat_t has wrong size for Android armv7a Product: D Version: D2 Hardware: Other OS: Other Status: NEW Severity: normal

Re: How does one attach a manifest file to a D executable on Windows?

2024-06-02 Thread solidstate1991 via Digitalmars-d-learn
On Saturday, 25 May 2024 at 19:51:25 UTC, John Chapman wrote: Not tested but from memory I do this: 1) Copy that first XML snippet from the page you linked, save to a file called example.exe.manifest 2) Create a resource script file called resources.rc, with this at the top: 1 24

[Issue 24578] New: Memory leak in rt.minfo sortCtor

2024-06-02 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=24578 Issue ID: 24578 Summary: Memory leak in rt.minfo sortCtor Product: D Version: D2 Hardware: All OS: All Status: NEW Severity: minor Priority: P1

[Issue 24560] dmd crash on imported function with default parameter containing `new`

2024-06-02 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=24560 --- Comment #7 from Dlang Bot --- dlang/dmd pull request #16553 "merge stable" was merged into master: - ee4f5a04ffa272cf9c9fa4a134fc71559d0851b3 by RazvanN7: Fix Bugzilla Issue 24560 - dmd crash on imported function with default parameter

[Issue 24504] ImportC: Enum declarations with a mixture of `int` and `uint` literal values cause errors, when targeting Windows, when debug info generation is enabled.

2024-06-02 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=24504 Dlang Bot changed: What|Removed |Added Status|NEW |RESOLVED Resolution|---

[Issue 24504] ImportC: Enum declarations with a mixture of `int` and `uint` literal values cause errors, when targeting Windows, when debug info generation is enabled.

2024-06-02 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=24504 Dlang Bot changed: What|Removed |Added Keywords||pull --- Comment #2 from Dlang Bot ---

[Issue 24576] Now that OMF support has been dropped, the standard library should be called `phobos32` not `phobos32mscoff`

2024-06-01 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=24576 --- Comment #2 from Nicholas Wilson --- the different directory and the smattering of Makefiles changes, compiler sc.ini, etc. was part of the reason that this was such a PITA to try to change it. We should have it configured in one place ideally.

[Issue 24577] Struct with constructor returned from C++ wrong

2024-06-01 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=24577 kinke changed: What|Removed |Added CC||ki...@gmx.net --- Comment #1 from kinke --- I'm

[Issue 24576] Now that OMF support has been dropped, the standard library should be called `phobos32` not `phobos32mscoff`

2024-06-01 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=24576 kinke changed: What|Removed |Added CC||ki...@gmx.net --- Comment #1 from kinke --- I'd

[Issue 15587] Enable use of D keywords as identifiers when interfacing to C/C++

2024-06-01 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=15587 Tim changed: What|Removed |Added CC||tim.dl...@t-online.de --- Comment #4 from Tim ---

[Issue 24577] New: Struct with constructor returned from C++ wrong

2024-06-01 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=24577 Issue ID: 24577 Summary: Struct with constructor returned from C++ wrong Product: D Version: D2 Hardware: x86_64 OS: Windows Status: NEW Severity: normal

[Issue 24577] Struct with constructor returned from C++ wrong

2024-06-01 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=24577 Tim changed: What|Removed |Added Keywords||C++ --

[Issue 24576] New: Now that OMF support has been dropped, the standard library should be called `phobo32` not `phobos32mscoff`

2024-06-01 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=24576 Issue ID: 24576 Summary: Now that OMF support has been dropped, the standard library should be called `phobo32` not `phobos32mscoff` Product: D Version: D2

[Issue 24576] Now that OMF support has been dropped, the standard library should be called `phobos32` not `phobos32mscoff`

2024-06-01 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=24576 Nicholas Wilson changed: What|Removed |Added Summary|Now that OMF support has|Now that OMF support has

Re: Socket and spawn()

2024-05-31 Thread Jonathan M Davis via Digitalmars-d-learn
On Friday, May 31, 2024 6:28:27 PM MDT Andy Valencia via Digitalmars-d-learn wrote: > On Friday, 31 May 2024 at 16:59:08 UTC, Jonathan M Davis wrote: > > Speaking as an old kernel engineer for the Sequent multiprocessor > product line, this is all very comfortable to me. I'm very g

Re: Socket and spawn()

2024-05-31 Thread Andy Valencia via Digitalmars-d-learn
On Friday, 31 May 2024 at 16:59:08 UTC, Jonathan M Davis wrote: Strictly speaking, unless you're dealing with a module or static-level variable, the object is not in TLS. It's treated as thread-local by the type system, and the type system will assume that no other thread has access to it, but

[Issue 24135] Eponymous template member overloads not shown as call candidates

2024-05-31 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=24135 Dlang Bot changed: What|Removed |Added Status|NEW |RESOLVED Resolution|---

Re: Socket and spawn()

2024-05-31 Thread Andy Valencia via Digitalmars-d-learn
On Friday, 31 May 2024 at 19:48:37 UTC, kdevel wrote: Have you taken into consideration that each of the (pre-spawned) threads can call accept()? Your program may also accept in multiple processes on the same socket. [1] Yes, but I am planning on some global behavior--mostly concerning

[Issue 24575] sumtype fails to match lambdas with anonymous arguments

2024-05-31 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=24575 Richard (Rikki) Andrew Cattermole changed: What|Removed |Added CC||alphaglosi...@gmail.com

[Issue 24575] New: sumtype fails to match lambdas with anonymous arguments

2024-05-31 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=24575 Issue ID: 24575 Summary: sumtype fails to match lambdas with anonymous arguments Product: D Version: D2 Hardware: x86_64 OS: Linux Status: NEW

Re: Socket and spawn()

2024-05-31 Thread kdevel via Digitalmars-d-learn
On Friday, 31 May 2024 at 16:07:23 UTC, Andy Valencia wrote: I'm coding a server which takes TCP connections. I end up in the main thread with .accept() which hands me a Socket. I'd like to hand this off to a spawn()'ed thread to do the actual work. Have you taken into consideration that

[Issue 23487] std.experimental.logger assigning FileLogger to sharedLog no longer works

2024-05-31 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=23487 Forest changed: What|Removed |Added CC||fores...@nom.one --- Comment #2 from Forest ---

[Issue 24261] Cannot define calling convention of a function prototype in a function scope

2024-05-31 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=24261 Nick Treleaven changed: What|Removed |Added CC||n...@geany.org --- Comment #1 from Nick

  1   2   3   4   5   6   7   8   9   10   >