Re: Windows API: GetUserName: Retrieve the name of the user associated with the current thread.

2023-08-20 Thread BoQsc via Digitalmars-d-learn
Update: GetUserName by print to stdout Main function has been updated with `string[] args` and a new feature: ``` if (args.length > 1 && args[1] == "print") { write(username); } ``` Usage: `WindowsGetUserName.exe print` Demonstration

Re: Spec for the ‘locality’ parameter to the LDC and GDC builtin magic functions for accessing special CPU prefetch instructions

2023-08-20 Thread Iain Buclaw via Digitalmars-d-learn
On Saturday, 19 August 2023 at 19:23:38 UTC, Cecil Ward wrote: I’m trying to write a cross-platform function that gives access to the CPU’s prefetch instructions such as x86 prefetch0/1/2/prefetchnta and AAarch64 too. I’ve found that the GDC and LDC compilers provide builtin magic functions