Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
benhoyt
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
40 ms
·
481.
▲
by
benhoyt
6y ago
Neat! I'm curious -- would it be possible to share a few (non-sensitive!) details about how this works / what this looks like?
482.
▲
The State of the AWK
(lwn.net)
213 points
by
benhoyt
6y ago
|
86 comments
483.
▲
by
benhoyt
6y ago
I love this about Go. All functions are simple and synchronous, but if you want to call them concurrently, just "go SlowThing()" and coordinate with a channel. Compare that to the async stuff in C#, Python, etc -- it's bolted
484.
▲
The A-Z of programming languages: AWK (2008 interview with Alfred Aho)
(computerworld.com)
1 points
by
benhoyt
6y ago
|
0 comments
485.
▲
by
benhoyt
6y ago
Thanks -- I replied in full there. I reused your title, which I can see was confusing. However, this is all my own writing and research, primarily from the official (draft) release notes, new linker design doc, golang-dev, and GitHub issues
486.
▲
by
benhoyt
6y ago
Thanks! As a service/app developer, I'm not familiar with a lot of that terminology, but I'm very thankful that someone on the Go team is.
487.
▲
by
benhoyt
6y ago
These days when I see a fast, reliable CLI tool I think "this has got to be written in Go" and a lot of the time they are. Some examples: the new GitHub CLI, Docker, Hashicorp tools, ngrok (though v2 is not open source), Caddy, th
488.
▲
by
benhoyt
6y ago
Re "go new": I think part of the problem with that is that people have quite different ideas of what a good project structure is. It also varies a lot between a simple CLI tool (for which main.go and maybe go.mod is enough) and a
489.
▲
by
benhoyt
6y ago
Nice! I'm not sure exactly why a rather minor update to the GitHub CLI is near the top of HN, but looking at your project (and then seeing the link to your presentation) made it worthwhile for me.
490.
▲
by
benhoyt
6y ago
The one thing I found tricky was getting the systemd config file correct (I'm not a Linux pro). Looks like he's addressed that too, with this README and demo systemd config -- nice! https://github.com/caddyserver&#
491.
▲
by
benhoyt
6y ago
I recently switched my site from using Amazon Linux 1 + Apache + manual setup to Amazon Linux 2 + Caddy 2 + automated Ansible setup. The documentation for Caddy 2 wasn't quite 100% at the time, but it looks like it's in much bette
492.
▲
by
benhoyt
7y ago
Yeah, you're right. On its homepage it's labelled as "fast as C extensions" and "often faster than C implementations". I guess because C implementations often use inferior data structures -- I used to say "
493.
▲
by
benhoyt
7y ago
This sounds exactly how the excellent Python Sorted Containers library works, and achieves "faster than C" performance in pure Python by effective use of the bisect module (which itself is written in C). http://www.gran
494.
▲
by
benhoyt
7y ago
They address that somewhat in the discussion section: > C++ provides many features for more explicit memory management than is possible with reference counting. For example, it provides allocators [35] to decouple memory management from
495.
▲
by
benhoyt
7y ago
2. The real question is why Graham is teaching BASIC instead of Lisp.
496.
▲
Betterment's Engineering Principles
(betterment.github.io)
1 points
by
benhoyt
7y ago
|
0 comments
497.
▲
by
benhoyt
7y ago
This is actually a feature in Go, but you leave off the "true" condition entirely: https://tour.golang.org/flowcontrol/11 I quite like it, as it cuts down on the amount of brace and if/else if noise.
498.
▲
by
benhoyt
7y ago
Awesome, thanks muchly, Bob! Reading and learning from "Crafting Interpreters" inspired four of my own fun projects (the first three on github.com/benhoyt): littlelang, my first little language interpreter, in Go; loxlox, a L
499.
▲
by
benhoyt
7y ago
What roles are remote (not just now with COVID, but in the longer term)? I notice on your jobs page that most of them have a physical location listed.
500.
▲
by
benhoyt
7y ago
That's very interesting to me. Do you have a source or more info about this?
501.
▲
by
benhoyt
7y ago
In that case, would you mind (pretty please? :-) writing a few paragraphs here about how you did this, technically speaking?
502.
▲
by
benhoyt
7y ago
His original announcement is in this video (starts at around 34:00): https://www.twitch.tv/videos/568019342 ... one of the questions asked in the chat (55:07) is "How?" and he says he's going to answer t
503.
▲
by
benhoyt
7y ago
asiekierka, I'm very impressed. How did you go about building this? Did you start with the assembly and work backwards to Pascal? Did you use a Pascal decompiler? Even then I can't imagine how you managed to get the output byte-fo
504.
▲
by
benhoyt
7y ago
Agreed! I got into AWK not because I thought I needed AWK, but because I'd heard "The AWK Programming Language" was a great book ... and sure enough, it was. Like TCPL and TGoPL, all of which share Kernighan as an author, a c
505.
▲
by
benhoyt
7y ago
There's value in doing both in certain cases (as long as you're definitely escaping output), but I'd be careful about the motivation. You say: "Sanitize your inputs so that it can be safely stored in your data store"
506.
▲
by
benhoyt
7y ago
Good call! Guess I was thinking of Captain Kidd. Fixed, kind of. :-) Then again, I'm not sure what Billy the Kid's doing surfing the web in 2020 either...
507.
▲
Don’t try to sanitize input – escape output
(benhoyt.com)
297 points
by
benhoyt
7y ago
|
280 comments
508.
▲
SEO for Software Engineers
(medium.com)
4 points
by
benhoyt
7y ago
|
0 comments
509.
▲
by
benhoyt
7y ago
Sounds about right! Here's another: https://benhoyt.com/writings/learning-go/ ... I ported a medium-sized web backend in Python to Go. "Due to Go’s static typing and because I was using fewer libraries,
510.
▲
by
benhoyt
7y ago
As someone who built Forth compilers back in the day, I really like this language. There's a nice overview of Factor as a paper here: https://factorcode.org/slava/dls.pdf and a Google tech talk video of Slava Pest
More ›