Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
tubthumper8
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
8 ms
·
61.
▲
by
tubthumper8
3y ago
You can also edit CSS in the browser and have it automatically sync to your source code without having to do any manual copying, look up "CSS mirror editing"
62.
▲
by
tubthumper8
3y ago
I'm not on the V8 team, so can't say why grep didn't find the vulnerabilities. That would perhaps be a good suggestion to make to them!
63.
▲
by
tubthumper8
3y ago
> Rust has bounds-checked and non-bounds-checked array accesses depending on the developer's preference, and so does C++ You're making it sound like these are the same, the difference is the defaults Unsafely accessing an eleme
64.
▲
by
tubthumper8
3y ago
ts-node does type checking by default using `tsc`. Bun does not, so this isn't an equivalent comparison
65.
▲
by
tubthumper8
3y ago
As far as I'm aware, Rust has been doing this for 9 years now (77 new versions), I'm not sure if that's been "expensive" but people seem to like it and it's working well so far
66.
▲
by
tubthumper8
3y ago
They previously announced [1] these would be removed in v17, did that change? [1] https://blog.angular.io/angular-v16-is-here-4d7a28ec680d
67.
▲
by
tubthumper8
3y ago
> I would say OOP revolves around the concept of modeling real-world entities or concepts as objects in code. This is just data modeling, has nothing to do with OOP.
68.
▲
by
tubthumper8
3y ago
Yeah this is why I always chuckle when people claim that OOP "models the real world". Oh, because your "FooWidgetController", "FooWidgetService", "FooWidgetRepository" are all real world things?
69.
▲
by
tubthumper8
3y ago
Maybe. It depends what the definition of "object-oriented" is, which depends what the definition of "object" is. Neither of which has any semblance of agreement among programmers. Many people would define an object as so
70.
▲
by
tubthumper8
3y ago
Definitely agree that mainstream languages are adopting functional features, but records aren't a functional feature. Records are basic data modeling and something that has been around since the beginning of programming languages, whet
71.
▲
by
tubthumper8
3y ago
I know it's a simple example, but the Maybe class should probably use a null check internally rather than a truthy check, so that types like number and string which have falsy values that are nonetheless valid for a use case can be use
72.
▲
by
tubthumper8
3y ago
What's it missing? flatMap/bind/whatever that's called?
73.
▲
by
tubthumper8
3y ago
Interesting idea! As an example, if the template was "<span>{name}</span>" then if I follow you correctly, it would generate some `Model` struct/interface/whatever that would have a `name: String` field.
74.
▲
by
tubthumper8
3y ago
Bundling (including dead code elimination) is more used for frontend code to reduce the amount of JavaScript sent over the wire to browser. You don't need to bundle server-side code unless you're using a cloud provider that limits
75.
▲
by
tubthumper8
3y ago
Some more details on `await` as a postfix operator rather than prefix https://blog.ceejbot.com/posts/postfix-await/
76.
▲
by
tubthumper8
3y ago
In this example, how do you get an instance of `Age`? i.e. If a user is asked for their age and they type in a number
77.
▲
by
tubthumper8
3y ago
TypeScript has discriminated unions if that's what you were thinking of https://www.typescriptlang.org/docs/handbook/2/narrowing.htm...
78.
▲
by
tubthumper8
3y ago
I'm struggling to understand the context of this comment. What do the inventors of V8 and C have to do with this topic?
79.
▲
by
tubthumper8
3y ago
Most? Looks like 3 out of 20 people https://react.dev/community/team
80.
▲
by
tubthumper8
3y ago
> The language in this documentation is self-serving to PL nerds and needs to be rewritten to target normal people. Anything else is just needless elitism and wankery, IMHO. Which documentation are you referring to, the TypeScript docume
81.
▲
by
tubthumper8
3y ago
> Do you mean errors.Unwrap? There is no errors.Wrap function. I was referring to this errors.Wrap function: https://pkg.go.dev/github.com/pkg/errors#Wrap I'm not a Go expert, is this function deprecated&#
82.
▲
by
tubthumper8
3y ago
Thanks for the clarification on the panic function signature - I missed it when checking the spec but it's definitely in there and defined as taking `interface{}` https://go.dev/ref/spec#Handling_panics
83.
▲
by
tubthumper8
3y ago
Are you referring to C? I think the comment's point would be that when C came out there were no search engines, so nobody would've considered that. When Go came out, not only were search engines a critical everyday software, the G
84.
▲
by
tubthumper8
3y ago
There's a (possibly non-exhaustive) list from a Reddit comment here. I can paste it if needed, otherwise will just link it: https://www.reddit.com/r/golang/s/wt1vpPtLgc
85.
▲
by
tubthumper8
3y ago
Disclaimer: just trying to directly answer the question, but also may be wrong in many ways. Please correct me. I thought one difference was that a panic in a goroutine kills the whole process vs. an exception in a Java thread would just ki
86.
▲
by
tubthumper8
3y ago
To me, being able to represent "A or B or C" is a bare minimum of a type system.
87.
▲
by
tubthumper8
3y ago
Rust also has automatic formatting [0] I don't think the tooling is why there is a perceived "Go vs Rust" culture, I think that's due to (somewhat) overlapping use cases, or more probably that they were developed and cam
88.
▲
by
tubthumper8
3y ago
The core problem with null/nil in Go (and Java) is that it is not modeled in the type system. In Java, any reference (which is most types) can be secretly null which is not tracked by the compiler. Go one-ups this and has the same conc
89.
▲
by
tubthumper8
3y ago
For reference, the GitHub thread is: https://github.com/golang/go/issues/12914
90.
▲
by
tubthumper8
3y ago
Why are Things Expensive? No.
More ›