Archive for May 5, 2015

Tuesday, May 5, 2015

Graduation

Soroush Khanlou:

This move from method to object is sometimes awkward, since we’re translating from a verb to a noun. It’s necessary, though. This technique is a great one to hide complexity, and it can reveal abstractions that weren’t apparent before.

[…]

We can keep extracting like this until we’re satisfied. The class gets continually flattened and methods get continually shortened until it’s sufficiently elegant. Any method inside here that’s still too long and complex is subject to the same treatment of being hoisted from a method to a bona fide object.

Integer Overflow Bug in Boeing 787

Edgar Alvarez (comments):

“A Model 787 airplane that has been powered continuously for 248 days can lose all alternating current electrical power due to the generator control units simultaneously going into failsafe mode,” the FAA said in a statement warning of the flaw. “We are issuing this AD to prevent loss of all AC electrical power, which could result in loss of control of the airplane.” Boeing, for its part, is aware of the problem and has reset the power on 787 Dreamliners currently in service.

Matt McGuire:

It all has to do with Integer math overflow. It could potentially happen on any hardware/software platform. It’s usually a call to something like GetElaspedTime() that will return the amount of milliseconds since the device powered on. If it returns a 32 bit integer (most embedded processors) the maximum is 248 days and some change.