Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
Rusky
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
40 ms
·
391.
▲
by
Rusky
7y ago
GraalVM doesn't solve the same problems as WebAssembly- it has no stable, portable format for those polyglot program definitions. GraalVM is certainly something you could use as part of a WebAssembly implementation, though.
392.
▲
by
Rusky
7y ago
In the most recent issue, there was in fact demonstrated "unsafe-bleed," in the sense that client code could hit undefined behavior by using public safe APIs a particular way.
393.
▲
by
Rusky
7y ago
Many (if not most) ASTs, especially in batch compilers, do not preserve comments, whitespace, or even all of the actual syntax. Even the diagnostics information you're referring to are insufficient to reproduce the whitespace. Further,
394.
▲
by
Rusky
7y ago
The ABI discussed here is a bit higher level than that. Even with a fixed ABI for vtables, calling conventions, etc. you still have to care about what happens when you change a "vocabulary type" in the standard library- some chang
395.
▲
by
Rusky
7y ago
> Anyone who expects a database to always have records and that the absence of a record is an "exception" has a very strange way of thinking. This isn't something you can make universal statements about, because it depends
396.
▲
by
Rusky
7y ago
They are less multiplatform than you would like, though. MacOS is stuck on an old version of OpenGL with no chance of updating since they deprecated it, and it has no Vulkan support (ignoring translation layers like the one Rocket League us
397.
▲
by
Rusky
7y ago
> ... generics, traits ... Again, these are just as much a single feature as Zig comptime. Traits are like comptime types, or else (closer to what Zig does) comptime type variable introspection. > You'd get similar compile-time e
398.
▲
by
Rusky
7y ago
That's hardly an honest comparison. I can just as easily split comptime into "type comptime," "value comptime," "comptime blocks," "builtin functions like @isInteger," and "inline control st
399.
▲
by
Rusky
7y ago
I don't see how Zig comptime is any simpler than Rust. Frankly, it seems more of a kluge. But we've already been over this before. :)
400.
▲
by
Rusky
7y ago
> If you run tests on a Zig program out of the box you won't have array overflows; that's not what you get in C and C++. Build a C program in the right mode (also required for Zig) and you get exactly the same thing.
401.
▲
by
Rusky
7y ago
> Take a look at some of the checks Zig has. I did, to make sure I wasn't missing something. There's nothing new there, and some things are missing. (This is not bad, Zig is still in development, but it's not exactly a new
402.
▲
by
Rusky
7y ago
C and C++ have plenty of analogous checks- debug assertions in the standard library, runtime checks for uninitialized memory, sanitizers, etc. Do we have an idea how effective they are there? Do we have reason to expect Zig's to be any
403.
▲
by
Rusky
7y ago
You've been asserting this for a while now, without really describing what you mean by "Zig's approach." What features are you thinking of here, and why would we expect them do any better than existing tools in C++ (or e
404.
▲
by
Rusky
7y ago
I'm reminded of this classic comment: https://www.reddit.com/r/rust/comments/67x46l/announcing_rus...
405.
▲
by
Rusky
7y ago
The nastiest response I encountered was at the end of the GitHub issue thread, right before the maintainer deleted it. (He also cites it in his postmortem.) It said things like "you should never write Rust again," with very little
406.
▲
by
Rusky
7y ago
Reminds me of this Vernor Vinge novel: https://en.wikipedia.org/wiki/A_Deepness_in_the_Sky Set around a star that alternates between bright and dim, with a species that hibernates during the dim periods.
407.
▲
by
Rusky
7y ago
The only reason QUIC is built on top of UDP is because ossification prevents it from being built on top of IP. It's essentially at the same level as TCP- and provides similar mechanisms to avoid UDP's issues.
408.
▲
by
Rusky
7y ago
> Rust does not have shared libraries Nonsense. Rust has shared libraries just as much as C and C++ do. Distributions can and do build individual Rust crates as shared libraries, and crate authors can go further and offer a shared librar
409.
▲
by
Rusky
7y ago
Your complaint is purely syntactic- `&Cell<T>` exactly the same thing as `&multimut T` semantically. Other forms of interior mutability genuinely are more than a tweak to borrowck- `RefCell` has a counter, `Mutex` adds synchro
410.
▲
by
Rusky
7y ago
Long-term documentation is not the reason logs are useful. Asynchronous communication is the reason logs are useful. That is, you can ping people who are offline, or with a flaky network connection (e.g. mobile, where you can't keep a
411.
▲
by
Rusky
7y ago
Even when not using LLVM, Jai still does "codegen twice." Most compilers today (even JITs) have at least one IR in between the syntax tree and the generated code. The existence of LLVM IR is not the problem- rather, it's ho
412.
▲
by
Rusky
7y ago
Editions solve an entirely separate problem, they were never meant to be LTS language snapshots. For example, C++ is considering adopting them in addition to their current versioning scheme: http://open-std.org/JTC1/S
413.
▲
by
Rusky
7y ago
It's a binary format originally based on minified JS, with a standard textual form, and which can be viewed and debugged with exactly the same tools (and ease) as minified JS.
414.
▲
by
Rusky
7y ago
Yes, but it's not used that way in this snippet...
415.
▲
by
Rusky
7y ago
There's a `cmake` crate that you could use from `build.rs` the same way, or you could go the other direction and have your existing build system invoke Cargo or rustc.
416.
▲
by
Rusky
7y ago
No, it's bits of valid syntax thrown together informally to express an idea. There is no `!:` in Rust, and that `for` quantification never applies to types or bounds that way.
417.
▲
by
Rusky
7y ago
That's true but antiparallel to my point: C++ typename could have the same consistency as Rust's turbofish- its complicated rules are not necessitated by the lexer hack. (In a sense, the complicated rules are what enable the lex
418.
▲
by
Rusky
7y ago
But C++ could take the same route of consistency regardless of the lexer hack. The turbofish is a strict superset of `typename`, and everywhere C++ lets you skip it it could simply require it instead.
419.
▲
by
Rusky
7y ago
Rust has an equivalent to `typename`, and it even requires it more often- the turbofish.
420.
▲
by
Rusky
7y ago
I've never seen this before, are you sure it's an upstream Firefox thing?
More ›