Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
CryZe
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
10 ms
·
61.
▲
by
CryZe
4y ago
> And it's not like you are going to get a huge performance benefit using Rust or C++ over assembly script. Or do they? Unlike Assembly Script, Rust and C++ use LLVM, which is a lot better at optimizing than binaryen.
62.
▲
by
CryZe
4y ago
If those terms mean anything to you: const is an rvalue, static is an lvalue.
63.
▲
by
CryZe
4y ago
> In C++ the community "default" is `absl::flat_hash_map`/`folly::F14`, which use SIMD to compare a whole stripe of key-prefixes simultaneously. Just to be clear, the Rust HashMap does the same thing.
64.
▲
by
CryZe
4y ago
According to this comment on Reddit https://www.reddit.com/r/gaming/comments/wb4jl6/comment/ii5d... : - Stadia signed multimillion deal with EA for Fifa23 and is taking preorders for this game. - Sta
65.
▲
by
CryZe
4y ago
You can always just do let no_async = block_on(something_async);
66.
▲
by
CryZe
4y ago
> it just needs to filter out verbatim exact snippets so it only outputs original, unattributable code. That's a setting now.
67.
▲
by
CryZe
4y ago
You apparently can "opt out of public code" now. I didn't find an explanation for whether that properly limits it to permissive licenses though. Update: It seems like they check whether the code it emits matches the training
68.
▲
by
CryZe
4y ago
You can opt out of that.
69.
▲
by
CryZe
4y ago
You can write libraries against alloc on stable, but not any executables, because executables not using std need to specify the alloc_error_handler, which you can't do on stable yet: https://github.com/rust-lang/ru
70.
▲
by
CryZe
4y ago
That's not all it does. It "breaks" to the nearest "try" barrier. It's basically the desugaring of the Err branch in the ? operator, that you can't currently express yourself. It's mostly relevant for
71.
▲
by
CryZe
5y ago
They just extended the COLR spec to COLRv1 which essentially is a whole new canvas API in fonts: https://github.com/googlefonts/colr-gradients-spec/blob/main...
72.
▲
by
CryZe
5y ago
You can compile the C code to WASM and then compile the WASM to safe Rust (I wrote a prototype for this and it works). Though as with all WASM, it protects the environment from the C code, but the C code can still corrupt its own WASM memor
73.
▲
by
CryZe
5y ago
No, that has been deconfirmed on Reddit: Edit 2 https://www.reddit.com/r/rust/comments/qzme1z/comment/hlne24...
74.
▲
by
CryZe
5y ago
While I agree that Rust changed a lot, it was mostly fixing edge cases (like borrow checker limitations or associated types not being allowed to have generics) or obvious missing features in the language (const fn, const generics, async awa
75.
▲
by
CryZe
5y ago
One thing that is stable is marking a function as cold which usually has the effect of marking the calling basic block as unlikely.
76.
▲
by
CryZe
5y ago
One issue I've noticed is that indexing into a T[] array where T can't be undefined, results in the expression to be of type T, not T | undefined, despite an out of bounds index evaluating to undefined. I believe I've seen th
77.
▲
by
CryZe
5y ago
This was supposedly fixed by at least Safari 14.1 (or earlier).
78.
▲
by
CryZe
5y ago
Well arrays never allocate in the first place, but you'd need some sort of specialized iterator api that either: - Handles the iterator not being the same size as the array you want to collect the iterator into and turns it into some s
79.
▲
by
CryZe
5y ago
Funnily enough I just used Copilot to write a reasonably huge PR (it did like 95% of the work), which was indeed mostly a copy paste job (the whole library is a SIMD library with lots of similarities between the different types and operatio
80.
▲
by
CryZe
5y ago
I don't fully understand it either, but they seem to be merged into linux-next, whatever that exactly means.
81.
▲
by
CryZe
5y ago
> Run out of hearts, you're restricted from proceeding further in your studies. You must buy hearts to stay on their platform. This is not true. It just means you made enough mistakes that you should use their practice mode rather t
82.
▲
by
CryZe
5y ago
The equivalent list for Windows 10 is missing many CPUs that run Windows 10 just fine... so yeah I don't think this list means anything for the actual consumer.
83.
▲
by
CryZe
5y ago
It is also released in Firefox (x86 only, ARM is in the next release iirc)
84.
▲
by
CryZe
5y ago
WASM still needs IndexedDB (or other storage) to store data in the browser.
85.
▲
by
CryZe
5y ago
There's also an open Pull Request for adding std::array::from_fn which calls the function / closure provided N times to initialize an array. This basically brings the array-init functionality into std. https://github.co
86.
▲
by
CryZe
5y ago
The "was been" certainly is a typo at least.
87.
▲
by
CryZe
5y ago
This is actually planned already. Not sure how far along the implementation and progress to stabilization is though.
88.
▲
by
CryZe
6y ago
Chrome definitely supports them on Windows at least, I don't know if it supports them on other operating systems. Here's a test page for the various kinds of color font tables: https://yoksel.github.io/color-fonts-
89.
▲
by
CryZe
6y ago
They could use the CPAL and COLR tables to turn each glyph / frame of the game into multiple RGBA layers.
90.
▲
by
CryZe
6y ago
rust-analyzer is not a compiler. They plan on sharing a lot of code though.
More ›