HNHacker News
TopNewBestAskShowJobs

hechang1997

66 karma · joined August 1, 2017

submissionscomments
hechang1997··on Google Begins Testing Extension Manifest V3 in Chrome Canary
Many many people use adblockers now. The amount of users they will alienate would be very high.
hechang1997··on My Favorite Programming Problem to Teach: Digit Length
I don't know about this. This feels like cheating rather than thinking outside of the box. Like when you ask a student to implement a vector in C++, instead of writing the code the student makes a wrapper around std::vector. Internally, `str` probably also use some equivalent of the naive solution implemented somewhere to convert a integer to its decimal string.
hechang1997··on Go Turns 10
C++ template metaprogramming may be overused and very difficult to use, but its prevalence despite such difficulty precisely shows how much such a type level metaprogramming tool is desired (compared to syntax level ones like lisp macros or text level ones like C preprocessor and various code generators). New programming languages should try to improve upon C++ template metaprogramming and make more powerful and effective metaprogramming language constructs, instead of completely abandoning the front.
hechang1997··on Async-await on stable Rust
Generics and compile time computation. I think Rust should achieve feature parity with c++ templates and constexpr.
hechang1997··on Rxdb: A reactive database where you can subscribe to the result of a query
The ideal case is that the DB can work out the difference in the subscribed query caused by the DB update so that the front end can make changes incrementally and doesn't have to rerender the entire list/table.
hechang1997··on قلب: a non-ASCII programming language written in Arabic
There's a “易(Easy)语言(Language)” in China which advertised itself as epitome of "Chinese Programming". It is basically a re-skinned C with a visual programming tookit, which does has its merit as visual programming tools were rare during that time. However, it only catched on in the "domain" of cheat engines and trainers, and eventually died out.
hechang1997··on قلب: a non-ASCII programming language written in Arabic
With the power of c preprocessor, you can program in any natural languages. /s
hechang1997··on Electron 7.0
the most important reason that leads to electron's adoption, I believe, is the flexibility and customizability of HTML UI compared to traditional widget-based ones.
hechang1997··on Electron 7.0
this library seems promising: https://github.com/zserge/webview
hechang1997··on Working with Errors in Go 1.13
Yes. Exception is generally a decent solution to error handling unless you're using RAII languages like C++/Rust where unwinding the stack doesn't work well with destructors.
hechang1997··on Easy Concurrency in Python
just like the author said in the end, this is literally the simplest case of concurrent programming where it's very easy to break your works down into independent pieces and no synchronization is required.
hechang1997··on Lesser Known Coding Fonts
what do you guys think is the best editor theme in bright light? I have been always using monokai but recently I have to work in bright light sometimes and it's quite hard to read.
hechang1997··on Why Isn't Functional Programming the Norm? [video]
That's exactly why people vectorize their code: to avoid slow loops in python and move them to the underlying c/cpp code.
← PreviousPage 2 of 2