According to the documentation
https://msdn.microsoft.com/de-de/library/yeby3zcb.aspx, _wfopen
already takes a wide-character string, not an ANSI string.
So
return _wfopen(name.tempCStringW(), mode.tempCStringW());
would be the correct way. All these weird ansi versions are
Windows
Hmmm...
Just found
https://www.securecoding.cert.org/confluence/display/seccode/void+SIG33-C.+Do+not+recursively+invoke+the+raise%28%29+function,
the bottom part Compliant Solution (POSIX) does raise() in the
signal handler.
However, I can't find it in the POSIX standard at
Hi Ketmar,
Hi Ali,
thank you!
On Sunday, 8 February 2015 at 09:42:14 UTC, Ali Çehreli wrote:
spawn(user, cucs, ubyte(3));
^to!
Other than that, it works.
(The Attributes are basically literal constants but the library
cannot know which are used in a given
Hi,
I'm trying to use immutable class instances and that seems to be
really difficult.
For example, with the following program I get an internal
compiler error:
cut-
import std.outbuffer : OutBuffer;
import std.typecons :
Hi rlonstein,
I've now read up on the opengroup pages about signal handling
(which references POSIX), and apparently it goes like this:
A signal can be delivered to a specific thread or to a process.
If it's delivered to a process, a random thread of that process
will receive it. If it's
Hi,
I've filed it with gdcproject.org before reading your reply. Will
it be forwarded to issues.dlang.org or should I file it there as
well?
Also, it seems there's a new DMD release underway right now, does
it still happen with that? (I tried but can't get it to build -
doesn't seem to
Hi,
if I want to clean up inside a signal handler and then exit the
process (as it would have without me handling it), what do I do?
Can I exit() inside a signal handler or should I use a more
direct quit now function? (after all, it could have been in the
middle of relinking the free list
Hi,
I'm trying to use BitArray instead of rolling my own. But how
does one use it?
I tried:
import std.bitmanip : BitArray;
int main() {
BitArray b;
b[2] = true;
return 0;
}
$ gdc l.d
$ gdb a.out
(gdb) r
Program received signal SIGSEGV, Segmentation fault.
Hello,
I'm trying to write some toy examples using threads in D.
Is the std.stdio.File thread-local or shared? Is flockfile used
when I synchronize on it?
I tried checking phobos myself and found some things I don't get
(in stdio.d):
alias FLOCK = flockfile;
this(this) { @trusted
Hi,
sigh, so I have to annoy you with the truth...
On Tuesday, 6 January 2015 at 17:15:28 UTC, FrankLike wrote:
How to prevent sensitive information is displayed when the
extension 'exe' is modified to 'txt' on windows?
By not putting it in in the first place. Everything else is no
good in
Hi,
I'm trying to learn how opDispatch works. Unfortunately, a very
simple example already doesn't work (error: no property 'a' for
type 'Foo'):
import std.stdio : writeln;
struct X {
int a;
}
class Foo {
X value;
template opDispatch(string s) {
I tried to make it even simpler to get to the core of the problem
I'm having:
...
template opDispatch(string s) {
alias value.a opDispatch;
}
The compiler then complains:
error: need 'this' for 'a' of type 'int'
I can only think: And? It's right there... it's a class instance,
Tobias: Thanks! Your version works. But now it's read-only.
Adam: Thanks, that was very illuminating! I tried and these work
indeed.
Is there a function like opDispatch which can be used (at compile
time) to refer to something by name whether or not it's custom?
(to access something like value.a safely. mixin and string
concatenation looks like would
Not sure how that works together with opDispatch. I am not sure
why you see safety reasons at compile time though.
Hmm, I'm not really worried about safety in this case (in many
other slightly different scenarios I am). More worried about
strange Unicode characters in fields I have no control
15 matches
Mail list logo