HackerTrans
TopNewTrendsCommentsPastAskShowJobs

dirt_like

no profile record

comments

dirt_like
·เดือนที่แล้ว·discuss
Slightly different idea to take Red Sea water, concentrate it, and flow into the Dead Sea to stabilize the water level in the Dead Sea which is a big problem. A billion or so was spent but the project is on hold for some combination of financial, political and environmental issues.

https://en.wikipedia.org/wiki/Red_Sea%E2%80%93Dead_Sea_Water...
dirt_like
·12 เดือนที่ผ่านมา·discuss
I have seen bit fields used in real code. Long ago. The reason I know it so well is that bit field updates are NOT atomic, and this caused a rare crashing bug under heavy load. Unless you read the header the code looks atomic.

S->buffer_free = 1;

This is a very serious limitation if the structure/class is being updated in a multi-threaded environment.