Better HN
topnewbestaskshowjobs
Log inSign up

TheMonarchist

64 karma · joined Jul 23, 2021 (5y ago) · 125 submissions

Someone's interests should be in line with those of the country.
Submissions

comment 4y ago · link · parent

This has been my primary research strategy for the past decade. It's digging gems from piles of rubbish, but when you find them you know that they are genuine.

comment 4y ago · link · parent

> I'm not aware of a way to construct an std::vector without throwing an exception.

You use an allocator with enough pool for whatever you need to do and avoid out of bounds access.

comment 4y ago · link · parent

> Calling Thing::default() clearly communicates that your just getting baseline values and not a lot of magical other initialization stuff going on— with a Thing::Thing() in C++, you're really at the mercy of whatever the project conventions are for how "fat" the constructor is going to be.

In C++ the constructor without arguments is called default constructor. Of course the expectations depend on conventions, but usually it's something from uninitialized garbage to an empty state.

comment 4y ago · link · parent

> Like maybe checked exceptions in C++ would work

https://en.cppreference.com/w/cpp/language/except_spec

comment 4y ago · link · parent

https://en.cppreference.com/w/cpp/io/basic_ios/exceptions

comment 4y ago · link · parent

I wish people were content at thinking that they know better. Right now they try to coerce others to act like they do in many parts of the world.

comment 4y ago · link · parent

To me it seems like a naturally arising question, but these days people aren't always rational so IDK.

comment 4y ago · link · parent

I wish I could say just "no" but nowadays you can't be sure where used laptops have been anyway. If you can't buy a new laptop, you could as well just buy one that has been in China.

comment 4y ago · link · parent

Experience-based guidelines for adopting C++11/14 at scale if you haven't already. (The experience requirement ruled out C++17 and C++20.)

10.

Embracing Modern C++ Safely (book)(informit.com ↗)

1 points · by TheMonarchist · 4y ago · 1 comment

comment 4y ago · link · parent

> Lambdas, Streams… Java is far from "80s style OOP" today.

Streams are a library feature. At a cursory look Boost seems to have had something similar since 2003: range adaptors[0].

Moreover lambdas have existed since 70s. They are modern only in the sense that Java got them in 2016 or so.

> It steals the best from the more avant-garde languages and builds it in coherently. That's no small task, so it takes few years.

That's a nice way to say that it gets new features only when they are undeniably useful.

> Therefore I wouldn't call Java "cutting-edge", but "modern" easily.

If Java is modern, C++ is cutting edge. It got the syntactic sugar for lambdas in 2011 - five years before Java.

However I may have put too much weight on "modern" in the question title. The demand for Java coders is going to be higher than the supply not unlike COBOL. If you can live with its limitations, you can make a living maintaining Java codebases for decades to come.

[0]: https://www.boost.org/doc/libs/1_78_0/libs/range/doc/html/ra... (Nowadays you would use Eric Niebler's Ranges-v3 when C++20 Ranges aren't available.)

comment 4y ago · link · parent

Java was designed to support 80s style OOP. While many mainstream languages do the same, it isn't particularly modern. I haven't followed Java's evolution in the recent years but as I recall it is the last language to adopt anything new.

comment 4y ago · link · parent

The interesting languages are those that don't need killer apps to succeed.

14.

Why Bloomberg engineers wrote Embracing Modern C++ Safely(bloomberg.com ↗)

3 points · by TheMonarchist · 4y ago · discuss

comment 4y ago · link · parent

Represent it as a bitmap - people are good at seeing patterns.

comment 4y ago · link · parent

> there are places on the internet that do the bare minimum of moderation and only remove illegal content. Unfortunately, only the worst members of society seem to frequent these types of forums

Could you link to worst examples? I think that finding these with search engines might be difficult.

comment 4y ago · link · parent

I tried to add "self-proclaimed" to it but updating seems to fail.

Update: resumbission with new title seems to be the way to go. Link: https://news.ycombinator.com/item?id=30252507

comment 4y ago · link · parent

I bumped into this recently. What do you think?

comment 4y ago · link · parent

The dynamics of the KJV were different. N competing Versions had caused divisions among the people, so the king ordered the making of one universal standard. The translation committee was aware of the goal and tried to avoid bias. Curiously it didn't result in N+1 competing Versions, but KJV was almost universally approved and many older Versions were retired. Readers have been content for over four centuries now.

In the case of NWT I think the bias matters because JWs deviate fatally from Christian orthodoxy.

comment 4y ago · link · parent

It is waiting its turn on my table btw.

comment 4y ago · link · parent

I have read it cover to cover multiple times and plan to continue reading for the rest of my life.

comment 4y ago · link · parent

> Even Christians these days pick an choose which parts of the Bible to read and then distil those down into short stories and songs rather than reading the texts in full.

It is lamentable if true. They don't know what they miss.

comment 4y ago · link · parent

> "The Sabbath was made for man, not man for the Sabbath."

There he implicitly refers to the creation week, that is the rationale for keeping the sabbath: "For in six days the LORD made heaven and earth, the sea, and all that in them is, and rested the seventh day: wherefore the LORD blessed the sabbath day, and hallowed it." (Exodus 20:11)

Jesus stresses that God gave an example to rest on the seventh day, for in his time it had been turned into a religious ordinance with strict rules to follow. IOW people were on their toes to avoid doing anything banned instead of resting.

> the character was very revolutionary and anti-establishment.

I guess you can get that impression depending on how much you put aside as "stuff about Jesus being God and also his son or whatever".

In Matthew 23 he says: "The scribes and the Pharisees sit in Moses’ seat: all therefore whatsoever they bid you observe, that observe and do; but do not ye after their works: for they say, and do not."

I would say that he opposed the establishment to the extent that it was wrong, but he definitely opposed rebellion:

And, behold, one of them which were with Jesus stretched out his hand, and drew his sword, and struck a servant of the high priest’s, and smote off his ear. Then said Jesus unto him, Put up again thy sword into his place: for all they that take the sword shall perish with the sword. (Matthew 26:51-52)

That was when Jesus was being captured.

comment 4y ago · link · parent

NWT also contains small changes to accommodate the Russellites' belief system.

I don't even speak English natively and can read KJV. I guess it just isn't more difficult than reading in foreign language in general.

Update: Samuel Johnson's dictionary helps with word definitions from 18th century. Noah Webster's dictionary is good too.

comment 4y ago · link · parent

How about designing a DR balloon instead? Costs would be divided by mass production.

comment 4y ago · link · parent

I guess they are addicted in spite of the flaws.

comment 4y ago · link · parent

This has been posted multiple times in the past 24 hours.
12345