Hacker News new | past | comments | ask | show | jobs | submit | akritid's comments login

This came to mind while considering your interesting point: After such a change, wouldn’t you feel the urge to inspect all users of the stricter return type and remove unnecessary handling of a potential null return?

I don't know about such urges. But sometimes there is no possibility to inspect all user code, e.g. when you are providing a library or API function.

Good point. In such case I would probably consider leaving the signature as is, even after tightening, and possibly offer a function with stricter signature for new code to use while deprecating the older variant. This would inform the users without rug pulling.

But that's not necessary in a language with union types of this sort. No rugs being pulled.

Looks fine (subjective) and there is also ctags


It is a personal choice of course, but some people enjoy the feeling of fully learning a piece of software, which is impossible with most.


Inferno is not a successor. For example you can have Golang for Plan 9 but doesn’t make much sense on Inferno. You would even run Inferno on Plan 9 on some scenarios. I suspect most people who know about Plan 9 also know about Inferno, but it’s just a different thing, does not supersede it in general.


Plan 9 => Inferno, which is still Plan

Alef => Limbo => Go.

Being able to backport Go into Plan 9, doesn't make sense in this context, that isn't how historical evolution works.

Also even Inferno has the necessary C infrastructure to port Go, if someone hasn't done it already.


I suspect you would have to port Go to run on Dis, the VM. C is for the OS. It’s a different design, without mmu. Plan 9 is still a classic OS with hardware isolation


The explicitly specialised generic packages are nice too


With some plumbing, it should be possible to follow links: match the URL with regex using the terminal and launch the link target in a new window.


I think they are not ordinary words that consume arguments directly from the stack. They also need to look ahead in the input stream of tokens. With support for quoted code, there seems to be no need for any other words operating at the token stream level, like conditionals and def. They just need to consume the stack. I am still digesting this so happy to be corrected.


Forth is very free-form, it doesn't require that your words be 'ordinary' in that sense. The : word isn't the only one that can consume from the input stream, neither is it the only word that can define words (such words are called defining words). The CONSTANT word, for instance, is a convenient syntax for defining a word to push a constant value onto the stack. [0]

You can even define your own 'mirror' of the : word, which involves some fiddly management of Forth's state, but it's doable. [1]

See also [2] on Forth's execution model and [3] on defining your own defining words.

[0] https://www.complang.tuwien.ac.at/forth/gforth/Docs-html/Con...

[1] https://www.complang.tuwien.ac.at/forth/gforth/Docs-html/Use... (The specific code shown is specific to Gforth, there's no stats or LATESTXT word in the ANS Forth standard.)

[2] https://www.forth.com/starting-forth/9-forth-execution/

[3] https://www.forth.com/starting-forth/11-forth-compiler-defin...


Oh, I don't know about that. Forth words can take control of the input stream! The ordinary parser eats space-deliminated tokens, sure, but how does the " word work? It takes over the input, and reads until it finds a terminal quote! It's wild: learning forth, you get used to RPN... but then you can implement an infix parser, and your "forth" can bootstrap a C-like language all in one source file.


Indeed using a quote to provide the word’s body seems very intuitive. I was asking about this on the retro forth IRC and turned out it could be bolted on to retro forth like: [ body … ] :name


It’s called split DNS. Can be implemented using dnsmasq


It can be implemented with dnsmasq but dnsmasq doesn't integrate with DHCP (edit, client) out of the box and requires a restart to apply configuration updates which invalidates query cache.

Edit-

I think split dns more commonly refers to serving different internal/private and external/public zones.

In this case, the DNS servers may return the same results but if I'm connecting to a VPN running some distance away, I don't want to route all DNS requests to that server--only the ones for domains on that network. The Domains directive allows configuring this https://man.archlinux.org/man/systemd.network.5#%5BNETWORK%5...

You can add a dhclient hook to reconfigure dnsmasq with `server=` directives to achieve the same thing, but, as mentioned, that still requires restarting the dnsmasq daemon. That usually manifests as: the VPN connection times out, the hook runs, dnsmasq is restarted, but a random web page or request will fail while the daemon is restarting. Sure, you could do SO_REUSEADDR or something to prevent the disruption, but, once again, this all just works out of the box with systemd-*


> dnsmasq doesn't integrate with DHCP

DNSMasq is a combined DNS and DHCP server! Of course it's integrated!


I'm talking about a local caching resolver, not a server running somewhere else on the network. dnsmasq doesn't ship with a DHCP client


I don't get your point. DNSMasq doesn't ship with a client, because it's a server. It's a cacheing resolver and a DHCP server that is usually run locally. I don't know of any system that doesn't come with its own built-in (or standard) DHCP client.

Can you clarify your objection to DNSMasq?


His objection is that it doesn't replace the use case that resolvd is supposed to solve. Which is to provide a local service that can redirect DNS queries dynamically as local interfaces go up and down, which is where the integration with a DHCP client comes in.


Oh, OK. Thanks.

Makes sense; a lot of the systemd ecosphere seems to be about hotdesking, plugging things in and unplugging them, moving from one wifi AP to another, hibernating and so on. I don't encounter these use-cases, on the whole, which is probably a large part of why I find systemd so annoying.


Yeah, and I have some sympathies with what systemd is trying to do here, but the implementation is often backwards and/or half-arsed.


Still no DHCPRELEASE.


Dnsmasq and resolvd is a beast to tame in homelab, and split network.


I think the main advantage of telnet is the line edit mode and local echo. It helps working over high latency connections.


Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: