Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
ywei3410
searching Neon…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
8 ms
·
1.
▲
by
ywei3410
3y ago
There's also the new JVM option which eludes me at the moment which sweeps the strings which are promoted to the older generation and interns them. Not certain about whether `String.intern` is permanently stored; I rather suspect that
2.
▲
by
ywei3410
3y ago
They are genuine issues, within Rust, but the way you /categorize/ the severity of the issue is different within language communities. They don't impact usability /much/ because of Rust's community, focus, size
3.
▲
by
ywei3410
3y ago
Not really third-party; ocaml-ppx is something similar to `javax` in the Java space? But it is optional and doesn't come bundled with OCaml. Recursive structures are only rare in Rust _because_ they suck to write and have terrible perf
4.
▲
by
ywei3410
3y ago
They require `sexp_of_t` and `t_of_sexp` because of their workflow being based on them; such as expectation testing [1] and tools such as [2]. It's a less noisy alternative to json for many people. [1] https://blog.janestree
5.
▲
by
ywei3410
3y ago
> You gave a beautiful answer about programming language You do the same thing as in Rust, Scala or Haskell and derive the printer [1]. Then at the callsite, if you know the type then you do `T.show` to print it or `T.eq`. If you don
6.
▲
by
ywei3410
3y ago
Would you not consider the object system to be ad-hoc polymorphism?
7.
▲
by
ywei3410
3y ago
I don't think this list is fair at all. > No standard and easy way of implementing interfaces Firstly another commenter has mentioned [1] modules as interfaces. There is also the object system [2] which I've seen used to great
8.
▲
by
ywei3410
3y ago
The other comments have already covered the how, but I'd like to add that the mechanism used extensively in Nix [1]. [1] https://nixos.org/
9.
▲
by
ywei3410
3y ago
The recipe is terrible, it neither has the detailed enough ingredients list nor the cooking technique for carbonara. Someone who hasn't cooked a carbonara just isn't going to be able to cook it with that recipe.
10.
▲
by
ywei3410
4y ago
I have seen this technique (send all the indexed search terms) a few times in the wild. Racket (a scheme derivative specifically made for teaching) has a search page where everything public is indexed [1] (see plt-index.js) and it works rea
11.
▲
by
ywei3410
4y ago
(IANAL) The most horrible part is that _they are allowed to drop their case anytime_ in the UK civil court. In previous cases when the accused has run out of money, the defendants have to pay their costs [1] to keep the trial running - with
12.
▲
by
ywei3410
4y ago
Emacs launches processes on the `PATH` so using `direnv`, you can change the `PATH` to the version of `rust-analyzer`/`gopls`/`python`/`psql`/`protoc` that you're using as well as setting the correct load paths for
13.
▲
by
ywei3410
4y ago
I really feel this is an infra problem rather than a dev problem though; the reverse-proxy should strip 5xx response bodies before the egress no?
14.
▲
by
ywei3410
4y ago
It's complex [1], OCaml does have a unboxed representation of floats in arrays [2] and records (provided all fields are floats), but elsewhere they are indeed boxed. [1] https://discuss.ocaml.org/t/optimizing-small
15.
▲
by
ywei3410
4y ago
Have you heard of ReScript [1]? [1] https://rescript-lang.org/
16.
▲
by
ywei3410
4y ago
Presumably because of emacs-ng [1], from the page " additive native layer over emacs, bringing features like Deno's Javascript and Async I/O environment, Mozilla's Webrender,". [1] https://github.com/
17.
▲
by
ywei3410
4y ago
Thanks for the link; not sure how I missed that completely while going through the thread documentation. I completely forgot about native modules completely... I don't think I disagree with anything you've said; though I would add
18.
▲
by
ywei3410
4y ago
I meant exactly that, both core JS and ELisp share the same model of a global interpreter where blocks of code can be interleaved and yielded (both manually and in response to external events). I wanted to know what in particular about JS y
19.
▲
by
ywei3410
4y ago
Regarding threads, they are definitely more co-operative co-routines than threads. However, if I recall there are only a few calls which can switch the context; the usual culprits, such as `thread-yield`, `sleep-for`, `accept-process-output
20.
▲
by
ywei3410
4y ago
Obligatory link: [1] https://github.com/ethan-leba/tree-edit
21.
▲
by
ywei3410
4y ago
It already has a process/event queue like JS since Emacs 26. What did you mean in particular?
22.
▲
by
ywei3410
4y ago
Emacs threads are not parallel and are co-operative rather than preemptive. The co-operative parts mean that you can guarantee atomic updates very easily when updating global variables or buffers so you don't run into some of the more
23.
▲
by
ywei3410
4y ago
I agree, You can /always/ go from `f : t -> r` to `f' : t option -> r option` with `Option.map` (ML-syntax, translate to w/e type syntax you're most familiar with), but the reverse is not true. I think that th
24.
▲
by
ywei3410
4y ago
I think it's worth noting that when we talk about a system operating on a set of components, it literally means a function which either reads and creates new components or entities or mutates existing components. Most "things"
25.
▲
by
ywei3410
4y ago
Nvidia has a visual difference, see the table [1]. [1] https://developer.nvidia.com/blog/introduction-turing-mesh-s...
26.
▲
by
ywei3410
4y ago
Yes, Haskell has green threads/co-routines. Racket /also/ has `thread` which is a co-routine but afaik you cannot pass the co-routine off to another native thread and there are certain constraints passing data between differe
27.
▲
by
ywei3410
4y ago
You are correct; typed racket does not use turnstile.
28.
▲
by
ywei3410
4y ago
Honestly the closure + `transpose` is really ugly as sin. I had to do a double take and reason through the steps which you took to get that particular snippet (while not reading the imperative one).
29.
▲
by
ywei3410
4y ago
Do you mean something like nyxt? [1] https://nyxt.atlas.engineer/
30.
▲
by
ywei3410
4y ago
It sort of does for modules [1] but not functions iirc. [1] https://nixos.wiki/wiki/Declaration
More ›