HNHacker News
TopNewBestAskShowJobs

smitherfield

1,770 karma · joined March 26, 2015

submissionscomments
smitherfield··on Researchers discover seven new Meltdown and Spectre attacks
I think that's his point; cloud is often network-bound, which can be orders of magnitude more costly.
smitherfield··on Apple Special Event [video]
Nope.
smitherfield··on Apple Special Event [video]
Expected in October along with a new iPad Pro and iMac. It's been some time since they launched any new Macs at an iPhone event.
smitherfield··on Apple Special Event [video]
When the original iPhone launched there was no other product like it; nowadays they need to be able to compete with Android on price.
smitherfield··on Apple Special Event [video]
There is no "iPad Max"?
smitherfield··on Apple can delete purchased movies from your library without telling you
Good customer service lesson here: Apple should've offered either a refund or to mail him the Blu-rays of the movies. I imagine this is a rare enough scenario they can easily afford for that to be their default response to such a support ticket, and the customer would most likely either tweet positively about the experience or not at all. (There still might be the odd unreasonable one who complains "I wanted to watch it now!" but that can't be avoided).
smitherfield··on The Power of Prolog
>A third of all airline traffic is handled by systems that run SICStus Prolog

But are those systems responsible for all the I.T. problems that are plaguing the industry?[1] (I've been under the impression the issues were primarily with COBOL/mainframe systems, but wasn't aware Prolog was so widely used by airlines).

[1] https://www.google.com/search?hl=en&q=airline%20computer%20f...

smitherfield··on Manufacturer 'make worthless' users devices after some stolen from a warehouse
Yeah, the burden is on the buyer not to purchase stolen goods. The manufacturer is certainly under no obligation to support them. In many states even unknowing possession of stolen goods is a crime, so many of the "users" here are in fact getting off lightly.
smitherfield··on Apple is a traditional business
>How long did it take the rest of the industry to catch up to the Mac from ‘84?

The Amiga was '85. It did take a while for PC-compatibles, of course.

smitherfield··on GCC 8.1 Released
"As before, values stored on the stack are scanned conservatively"

Why would values on the stack be garbage-collected at all? Do they mean scanning the stack for live references?

smitherfield··on Oracle owns “JavaScript”, so Apple is taking down my app
Nobody tell Oracle! https://github.com/WebKit/webkit/search?q=JavaScript
smitherfield··on A meta-analysis of C++ projects
That requires including the header. It's probably included in one of the other headers you included, but that's not required by the standard.
smitherfield··on A meta-analysis of C++ projects
> <initializer_list> is "built-in"

You still need to include the header for any of the following:

1. Constructors (or functions) with `initializer_list` parameters.

  template<typename T> struct S {
          vector<T> vec;

          S(initializer_list<T> il)
                  : vec(il) {}
  };
2. `initializer_list` literals in range-for loops.[1]

  for (int prime : {2, 3, 5, 7, 11})
           // ...
3. Named `initializer_list` variables.

  const auto primes = {2, 3, 5, 7, 11};
  const initializer_list<int> primes2 =
          {13, 17, 19, 23, 29};
> <iterator> is generally subsumed by "auto" and type inference.

The iterator adapters[2] are still pretty useful and (I thought?) commonly used.

Also, the "range access" and (new for C++17) "container access" free functions are very useful for writing template code that works with both C arrays and STL-style containers, but they're defined in many other headers.

[1] Useful with variadic templates:

  [](auto&&... args) {
          for (auto &&arg : {args...})
                  // ...
  }
[2] http://en.cppreference.com/w/cpp/iterator#Iterator_adaptors
smitherfield··on A meta-analysis of C++ projects
Allegedly, the quality of STL <regex> implementations leaves much to be desired.
smitherfield··on The Worst U.S. Maritime Disaster in Decades
The NTSB report says that it was the former, they were available but the captain had not configured the software settings to receive the hourly reports.

(Obviously, and hindsight is 20-20, hourly should've been the default).

smitherfield··on A man who spent $100K to remove a lie from Google
It's virtually impossible to win a libel case against a news media organization in the US.

If you're a "public figure" (and if more than one media org ran a story about some event involving you, the court will likely find that you are), then to win you need to prove not only that 1) the story was false, but also that 2) the journalist knew the story was false, prior to writing it, and 3) you suffered some material loss due to the story (e.g. being fired from your job).

In other words, journalists can publish speculation as fact (what we might call "lying"), so long as you can't prove they knew for certain it was false.

(In the very unlikely event you aren't found to be a public figure, you still need to prove the story was false and that you suffered a material loss, themselves pretty steep legal hurdles).

smitherfield··on The joy of max()
Nope, template type deduction never implicitly converts: https://godbolt.org/g/stZBK1
smitherfield··on The joy of max()
Does it compile the Linux kernel? ;)
smitherfield··on The joy of max()
No it doesn't, which is one of the major advantages it has over the C version; you have to do an explicit cast when the args are different types (almost always a potential source of subtle bugs).

Or what edflsafoiewq said: https://news.ycombinator.com/item?id=16721559

It is however trivial to write a version that works with distinct types, if that were really what you want.

  template<class L, class R>
  constexpr std::common_type_t<L, R> max(L l, R r) {return l < r ? r : l;}
smitherfield··on The joy of max()
That one-liner I posted works with both constant and non-constant expressions (and in fact is more likely to be evaluated at compile-time than the macro), is type-safe, and has no side effects assuming both arguments are arithmetic types or pointers (like all uses of `max` in the Linux kernel / C-language programs).
smitherfield··on The joy of max()
For Linux kernel purposes the following one-liner would suffice

    template<class T> constexpr T max(T l, T r) {return l < r ? r : l;}
smitherfield··on Water Slide That Decapitated Boy Violated Basic Design Standards
> [It] could be a load of crap and out of context falsehoods, written by authors who have an interest in raising the cap in Kansas.

That looks like an accurate description.

First of all, by the author's own admission, Rep. Schwab has never made any public statements regarding personal injury damages caps, and his only legislative action related to that subject is voting for a 2014 law which raised the damages cap. So claiming to be able to read his mind so as to justify a very nasty attack is quite uncalled for (IMO).

The Kansas Supreme Court upheld the damages cap 5-2 in 2012,[1] 2 years prior to the law raising the cap, so it's a real stretch (you might say a lie) to claim that law was passed "in order to head off the threat of the Kansas Supreme Court invalidating the whole damages cap scheme."

With respect to the concrete point the author raises, he's lying by omission. Economic damages (actual financial losses, no cap in Kansas) and non-economic damages ("pain and suffering," capped at $300k in Kansas) are two of the three types of damages that may be awarded in a civil case.

There are also punitive damages, which under Kansas law[2] are awarded when the jury finds "the defendant acted toward the plaintiff with willful conduct, wanton conduct, fraud or malice." Punitive damages are capped according to the formula

  (e) Except as provided
  by subsection (f), no
  award of exemplary or
  punitive damages
  pursuant to this section
  shall exceed the lesser
  of:

  	(1) The annual
  gross income earned by
  the defendant, as
  determined by the court
  based upon the
  defendant's highest
  gross annual income
  earned for any one of
  the five years
  immediately before the
  act for which such
  damages are awarded; or

  	(2) $5 million.

  (f) In lieu of the
  limitation provided by
  subsection (e), if the
  court finds that the
  profitability of the
  defendant's misconduct
  exceeds or is expected
  to exceed the limitation
  of subsection (e), the
  limitation on the amount
  of exemplary or punitive
  damages which the court
  may award shall be an
  amount equal to 1½ times
  the amount of profit
  which the defendant
  gained or is expected to
  gain as a result of the
  defendant's misconduct. 
1½ times the defendants' total (not yearly!) profits from Verrükt is almost certainly well above $20 million, and a judge might well allow the argument that the defendants demonstrated wanton and/or willful negligence in operating a) the entire Kansas City waterpark, capping damages at 1½ times its total profits, and/or b) the entire Schlitterbahn parent corporation, capping damages at 1½ times its total profits.

Considering that the Schwab family could have brought lawsuits on behalf of multiple injured parties, on multiple grounds, and against multiple defendants, then hypothetically, under Kansas law, my conservative back-of-the-napkin estimate is the defendants might have faced punitive damages totaling over ten billion dollars. (Which is not to say that amount would be awarded, just that Kansas law allows for it).

Additionally, there are several good reasons I can think of, completely unrelated to Kansas statute, for the Schwab family to sue in Texas instead of Kansas.

First of all, and I don't know whether this is the case here, liability disclaimers (as might be printed on amusement part tickets) usually require that lawsuits be brought in the state where the company is headquartered. In that case, it would be faster to simply sue Schlitterbahn in Texas rather than waiting for Kansas courts to rule on the disclaimer's validity.

Second, Rep. Schwab is a well-known and controversial figure in Kansas. Many people (e.g. the author), potentially including jurors or (less likely, but hardly unheard of) judges, may have difficulty assessing the case in an objective and detached manner.

Third, Texas has an unusually difficult process[3] for obtaining discovery from Texas-based parties in an out-of-state lawsuit.

As for the question of the author's preferred policy outcome, I disagree. I agree that it makes sense in terms of incentives and fairness for there to be a high or no cap on economic (for the plaintiff's actual financial loss) and punitive (for clear misconduct by the defendant) damages, at least for this type of case. Non-economic damages are much more nebulous and tend to be awarded based on how sympathetic the jury finds the plaintiff.

The purpose of personal injury law is to punish (and so discourage) negligent behavior, according to the defendant's degree of culpability. It is not to provide financial windfalls to plaintiffs according to how sympathetic they are (which encourages lawsuits). Whether it's a photogenic 10-year-old, Honey Boo-Boo's mom or Charles Manson who dies has no bearing on the question of whether the defendant is culpable and if so to what degree.

Jurisdictions where non-economic damages aren't capped are where you most often get the sort of case where average people lose all their assets and income because a child / veteran / homecoming queen / father-of-five / judge's aunt slips and falls on their driveway. If the law gets in the feelings-based business of deciding whether bad things happened to good people, the inevitable result is injustice. The law's proper domain are the facts-based businesses of redressing objectively-definable wrongs and of finding out and punishing misconduct.

Accordingly, I'd consider it proper for non-economic damages to be capped at a relatively low level, as in Kansas. Unfortunate as it may be, the law should reflect that just because a bad thing happened to a good person doesn't mean there's a villain to punish.

[1] http://www.cjonline.com/news/2012-10-05/kansas-high-court-up...

[2] http://www.ksrevisor.org/statutes/chapters/ch60/060_037_0001...

[3] http://canteyhanger.com/blog/2015/04/28/securing-discovery-f...

smitherfield··on Water Slide That Decapitated Boy Violated Basic Design Standards
The owner was just arrested as well,[1] and I'd bet that more will follow. My guess is the director of operations will get a plea deal in exchange for testifying against the others.

[1] http://www.kansascity.com/news/article206886324.html

smitherfield··on Water Slide That Decapitated Boy Violated Basic Design Standards
With notable exceptions (e.g. Therac-25, or self-driving cars) most of us have the luxury of working in spaces where mistakes may be annoying or costly, but not deadly.
smitherfield··on Nvidia Playing with Fire
>However, OEM computer manufacturers are a whole different story altogether. This is where AMD might get hurt by GPP. You see, GPP doesn't only apply to AIB manufacturers, it also applies to OEMs such as Dell, Apple, Lenovo or HP.

Perhaps in theory (emphasis on the perhaps, IANAL and neither is the author), but not in practice. Nvidia has a great deal of power over ATI, Asus etc. They have no power over Dell, much less Apple. Nvidia needs Dell and Apple far, far more than Dell or Apple needs Nvidia (they don't).

Nvidia and AMD are selling, if not identical products, then near enough for government work. If Dell decided to drop Nvidia from all their product lines, the impact on Dell would be negligible at worst, but it would be a catastrophe for Nvidia (while AMD would be making out like Scrooge McDuck). Apple? Nvidia sends Apple the corporate equivalent of drunken post-breakup apology voicemails (releasing Mac drivers for cards that aren't offered on Macs).

Nvidia's ability to enforce branding guidelines on Dell is nil. If Dell decided they'd rather brand "Nvidia" cards as "Dell GraphicsMaster 6000 SUX," Nvidia would have to roll with it.

smitherfield··on Safe-money: Money in the type system where it belongs (2017)
By causing them to have very large terms (numerators and denominators).
smitherfield··on Safe-money: Money in the type system where it belongs (2017)
And before someone says "hyperinflation," you could also store world GDP in nano-Zimbabwean dollars (with 1 USD = 6.69e11 ZWL).
smitherfield··on Safe-money: Money in the type system where it belongs (2017)
Rational arithmetic is not a good choice for money, since applications that deal with money probably involve user input and so can be trivially DOS-ed. Money should use decimal arithmetic, like COBOL. If it's good enough for banks, it's good enough for you.
smitherfield··on C++ Core Guidelines
Agreed. Minor quibble:

>This is a poor argument; the same could be said for almost all control flow statements: if/else

It's technically possible to implement if/else (and loop conditions) with unconditional jumps and offsets, but for reasonable instruction sets (that support conditional jumps) they won't be "goto under the covers."

smitherfield··on C++ Core Guidelines
`ssize_t` isn't standard C++ (it is required by POSIX); `ptrdiff_t` is only one character fewer than `gsl::index`.
← PreviousPage 2 of 25Next →