Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
zvrba
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
45 ms
·
421.
▲
by
zvrba
10y ago
Mistake #2 is just bizzare: who in their right mind could assume that wrapping an object in shared_ptr makes it threadsafe?! And the mistake is worded as if you should make these object thread-safe, which is just as bizzare.
422.
▲
by
zvrba
10y ago
You should be using a raw pointer, period. The list/tree destructor must be responsible for traversing and deleting the whole structure. If you have a linked list of, say, 10M elements linked by unique_ptr, deleting the head of the li
423.
▲
by
zvrba
10y ago
Most important advantage: RAII. You cannot forget to free the pointee even in the presence of exceptions. The "bugs" described in the article are just a case of not having read the manual. (Like, who in their right mind would assu
424.
▲
by
zvrba
10y ago
> OOP approach means that my process needs to know how to communicate with other processes via very specific protocols, which aren't very well defined (any process could describe its type of object). That's why we have IDL -- i
425.
▲
by
zvrba
11y ago
Sharing files is another convenience which is also in the free edition.
426.
▲
by
zvrba
11y ago
The nout about aio in glibc documentation says the following: "The current Linux POSIX AIO implementation is provided in user space by glibc. This has a number of limitations, most notably that maintaining multiple threads to perf
427.
▲
by
zvrba
11y ago
> Skylake doesn't support OSX (and there are people with reasons to want that). It's the other way around though?
428.
▲
by
zvrba
11y ago
Windows DLLs are not position-independent though. This has its advantages and disadvantages.
429.
▲
by
zvrba
11y ago
The compiler vendor is free to extend the standard and define UB.
430.
▲
by
zvrba
11y ago
>It so happens that the Windows API gets this right, This is my general impression on Win vs Linux: Windows offers more fundamental services as a core OS component, whereas Linux delegates this to a hodge-podge of competing and mutually
431.
▲
by
zvrba
11y ago
Absolute LoJack, with windows. It installs itself as a windows driver before/during the boot. It sends location once a day, or more often if you flag the device as stolen/missing. It can also remotely "brick" the device
432.
▲
by
zvrba
11y ago
This is a one-sided view. It can, and also is, used to implement theft-protection, thanks to which the police tracked the guy, he got convicted and I got my expensive laptop back. Yes, the guy reinstalled the OS, but the tracking SW survive
433.
▲
by
zvrba
11y ago
> endless operator-obfuscation nonsense a la C++ C++? Ever looked at some "advanced" Haskell code?
434.
▲
by
zvrba
11y ago
Well, it does not. Mathematics is a symbolic system invented by humans, but that system tells you nothing about the state of the world . Used correctly, it can be used to describe the world, but it can also be used to describe phenomena th
435.
▲
by
zvrba
11y ago
There are many new C ripoffs, but nobody seems to acknowledge Cyclone ( https://cyclone.thelanguage.org/ ) which is a lot older. It was even backed by a corporation (AT&T), but never succeeded. I wonder why.
436.
▲
by
zvrba
11y ago
Most insightful part for me was this one: > Many variations [he's talking about Rust] that seemed like they ought to run the same speed or faster turned out slower, often much slower. By contrast, in C++ it was surprisingly difficul
437.
▲
by
zvrba
11y ago
Confidential computing in the cloud, for example.
438.
▲
Uncovering the secret history of Myers-Briggs
(digg.com)
3 points
by
zvrba
11y ago
|
0 comments
439.
▲
by
zvrba
11y ago
When I'm bored I pick a random section and read it. I was really fascinated by the section on sorting networks for example. The real gems are the exercises and answers to them; there's at least as much useful/applicable stuff
440.
▲
by
zvrba
11y ago
He plans to remove that section in the next edition of the book :( I'd argue the section is very relevant since today's RAM works fastest when accessed sequentially.
441.
▲
by
zvrba
11y ago
Funnily I've been working on MLOC-sized C++ projects and almost never had a problem with lookup rules. On rare occasions where it was a problem, it was a compile-time problem and easily resolved. In any case, these rules do not fall un
442.
▲
by
zvrba
11y ago
No and no. Strictly proprietary technology which gives a real competitive advantage. Fun thing is, if you choose your data structures wisely, it's not even that hard to write; it ended up being under 2k lines of C++ code. GC was offlin
443.
▲
by
zvrba
11y ago
> If you start with C++, you're committed to a multi year project, that's what it takes to advance from novice to junior level. This is nonsense. Perhaps it's true to some degree if you try to "learn" C++ from tu
444.
▲
by
zvrba
11y ago
In my previous job we were evaluating HDF5 for implementing a data-store a couple of years ago. We had some strict requirements about data corruption (e.g., if the program crashes amid a write operation in another thread, the old data must
445.
▲
by
zvrba
11y ago
Right. I spend less than half of my income on neccessities (food, rent, etc. -- this I split with my partner) and recently I've found myself telling people that time is my most limited resource. So in the past couple of years I've
446.
▲
by
zvrba
11y ago
Nice to see that C++ is picking up speed after C++11. In my previous job I had to work with "legacy" C++, but now I'm working with "modern" C++. The difference is huge. C++11 features allow me to do more with less h
447.
▲
by
zvrba
11y ago
> I'm not sure that's the best example. In that case, the knowledge that the 'array' global never has its address taken allows you to perform the optimization. Separate translation units. For this to work, you'd
448.
▲
by
zvrba
11y ago
Secure boot would counteract this?
449.
▲
by
zvrba
11y ago
Triple fault? It seems that double fault exception (abort) should be triggered first.
450.
▲
Magit: a Git porcelain inside emacs
(magit.vc)
97 points
by
zvrba
11y ago
|
14 comments
More ›