Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
ChrisSD
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
11 ms
·
91.
▲
by
ChrisSD
3y ago
This has actually changed a bit in the last few years. In Windows 11 writing to `.\CON` will write to the file but writing to `CON` will still write to the console.
92.
▲
by
ChrisSD
3y ago
Imagine, for example, there's a really interesting scientific paper someone would love to talk about but it's in the field of Climate Science. Everyone knows the comments a blog post on it is going to get. And they're (almost
93.
▲
by
ChrisSD
3y ago
But our local "system" has a gigantic miasma of incandescent plasma on our doorstep. The Earth itself should not need to worry about entropy for a long while yet...
94.
▲
by
ChrisSD
3y ago
We're talking about default fonts that were last changed 15 years ago. 15 years between jobs isn't going to provide job security for an industry.
95.
▲
by
ChrisSD
3y ago
The ucrt is included as far back as Windows 7 (if you install updates).
96.
▲
by
ChrisSD
3y ago
There are two things here. The `unsafe` in an `unsafe { ... }` block is referring to the contents of the block. From the outside it is indeed safe to use as if it were safe code. No special requirements necessary. So, yes, from a certain po
97.
▲
by
ChrisSD
3y ago
Personally I think what people do in their free time is up to them, so long as it isn't hurting anyone. I don't think it's right for you to police that.
98.
▲
by
ChrisSD
3y ago
Your phrasing is interesting: "visible drama". Which suggests it would be "better" for Rust if it covered these things up :). Obviously that would be hard to do at the moment. It's actions are fairly open and there
99.
▲
by
ChrisSD
3y ago
Tbh, all I recall about pocket is it showed me a load of random content which I had no interest in, which felt spammy. And I think it needs a login for some reason? It certainly looked and felt like an external addon rather than a built-in
100.
▲
by
ChrisSD
3y ago
> (mainly because it would add ~30% more methods to Vec?) Sort of. Rather than bolting on fallible methods adhoc to an existing type, it was felt it would be better to take a step back and actually design this properly. This includes thi
101.
▲
by
ChrisSD
3y ago
core is part of the language (or at least, many parts of it are). The way that rustc currently splits this up is an implementation detail of rustc, not something that must be copied exactly. Rust without core is not Rust. It's not even
102.
▲
by
ChrisSD
3y ago
Hm... I'm not sure I understand. Why would you expect no_core to be specified? It's an implementation detail of rustc, not part of the language.
103.
▲
by
ChrisSD
3y ago
No, not really. It only supports "normal" win32 paths. You would have to mount it to a drive letter or directory.
104.
▲
by
ChrisSD
3y ago
You can now use ".\COM1" or "COM1.txt" but not a bar COM1.
105.
▲
by
ChrisSD
3y ago
I think what's missing from this discussion is an emphasis on how layered Windows paths are. The Win32 paths are like an emulation layer. They parse the given path and produce a kernel path. Win32 implements all the weird history you k
106.
▲
by
ChrisSD
3y ago
There are some APIs that have a lower limit than 260. But the limits can be bypassed using `\\?\` prefixed paths (except when using SetCurrentDirectory) or by enabling long paths https://learn.microsoft.com/en-us/window
107.
▲
by
ChrisSD
3y ago
This has actually changed in Windows 11. You can use "con.html" without fear. "con" is still a bit of a problem. ".\con" will work but not a bare "con".
108.
▲
by
ChrisSD
3y ago
Yes you can create files named `.` and `..`. However, any sensible filesystem driver will reject that name (spoiler: there does exist drivers that aren't sensible).
109.
▲
by
ChrisSD
3y ago
A stream name is somewhat more limited than that: > All Unicode characters are legal in a streamname component except the following: > * The characters \ / : > * Control character 0x00. > * A streamname MUST be no more than
110.
▲
by
ChrisSD
3y ago
> There is no "current directory" on an UNC share SetCurrentDirectory allows setting the current directory to a UNC share. https://learn.microsoft.com/en-us/windows/win32/api/winbase/...
111.
▲
by
ChrisSD
4y ago
Some variation on this has been consistently brought up for going on a decade now. At this point it's a HN meme. Its opposite is "cargo culting".
112.
▲
by
ChrisSD
4y ago
I'd also emphasise that fortunately most modern cryptography (outside of one time pads) does not rely on truly random numbers. So long as the sequence is unpredictable enough it's fine (i.e. you can't use known values to more
113.
▲
by
ChrisSD
4y ago
The bit after `>` is a quote, not my words. See https://en.cppreference.com/w/c/language/array for the source It's saying that C99 implemented flexible array members but before then some compilers int
114.
▲
by
ChrisSD
4y ago
According to the C spec, zero length arrays are explicitly illegal. > Zero-length array declarations are not allowed, even though some compilers offer them as extensions (typically as a pre-C99 implementation of flexible array members).
115.
▲
by
ChrisSD
4y ago
Kind of: > If the size of the space requested is zero, the behavior is implementation-defined: either a null pointer is returned to indicate an error, or the behavior is as if the size were some nonzero value, except that the returned po
116.
▲
by
ChrisSD
4y ago
> Even if you configure your account with 1,000,000 iterations, a compromised Bitwarden server can always tell the client to apply merely 5,000 PBKDF2 iterations to the master password before sending it to the server. The client has to r
117.
▲
by
ChrisSD
4y ago
It was designed as a security feature but it's been coopted to block competitors (or anyone else the CEO takes a personal disliking to). Therefore calling it an "anti-Mastadon" filter is accurate in this context, no matter th
118.
▲
by
ChrisSD
4y ago
Just to clarify further, note that actually preserving the "as if" behaviour does involve some complexity in the implementation. E.g. appending to WTF-8 has to be handled carefully to ensure it remains truly the same as doing so w
119.
▲
by
ChrisSD
4y ago
It does simplify things in places. One thing that isn't covered is that a code point is not necessarily a letter or vice versa. E.g. a single letter/symbol/emoji/whatever can be made up of multiple code points. So it isn
120.
▲
by
ChrisSD
4y ago
Windows NT uses actual Unicode under the hood (originally UCS-2, now UTF-16). Windows NT started development in 1989 and was released in 1993. Considering the Unicode standard was first published in 1991/2, I think Windows NT can be co
More ›