Is the NASDAQ using Xojo? 🤔

HA! Very timely for my article in the latest xDev Mag:

Berkshire Hathaway’s Stock Price vs. 32-Bit Integers

(Berkshire Hathaway’s Stock Price Is Too Much for Computers - WSJ)

Alexander Osipovich, reporting for The Wall Street Journal (News+ link):

Berkshire Hathaway Inc. is trading at more than $421,000 per Class A share, and the market is optimistic. That’s a problem. […] On Tuesday, Nasdaq Inc. temporarily suspended broadcasting prices for Class A shares of Berkshire over several popular data feeds. Such feeds provide real-time price updates for a number of online brokerages and finance websites.

Nasdaq’s computers can only count so high because of the compact digital format they use for communicating prices. The biggest number they can handle is $429,496.7295. Nasdaq is rushing to finish an upgrade later this month that would fix the problem.

That number will look familiar to the programmers among you: it’s the limit of an unsigned 32-bit integer. Using 32-bit integers for share prices, with four digits reserved for decimals, isn’t that crazy, though, given that no other stock in the U.S. has a share price that’s even close to the limit:

The U.S. stock with the second-highest share price, home builder NVR Inc., is trading just above $5,100 a share. Using compact formats that take up less memory can make software more efficient, a high priority in the world of electronic stock trading.

At the root of the problem is Mr. Buffett’s decadeslong refusal to execute a stock split of Berkshire’s Class A shares. The 90-year-old billionaire has signed birthday cards to friends with the message, “May you live until Berkshire splits,” according to Fortune magazine.

Wednesday, 5 May 2021

The concept of a currency data type is available in other programming languages.

Some kind of stupid untouched legacy until extreme necessity. Well, now they have extreme necessity.
It remembers me the Boeing updates. Boeing Still Used Floppy Disks to Update the Software in Its 747s - ExtremeTech

Naaa, Xojo currency is limited to only 2 digits reserved for decimals. Not useful for other countries where more digits are needed.

Xojo Currency has 4 digits.

it a scaled 64 bit integer
It has an implied decimal point

Sorry, still sasleep :rofl:

Right, it has 4 and I needed 6, long time not using it.

Xojo really needs 128 bit integers
Or just implement Bob Delaney’s open source infinite precision plugin as native types

You can use BigCurrency.
We have a sample project for that included with MBS Xojo Plugins, which uses LargeNumberMBS class.

See
https://www.monkeybreadsoftware.net/example-datatypes-bigcurrency.shtml

I think it was NOT open sourced back then, I try the plugin but it was not working alongside another one, cant replace the other so I ended up using my own class.

Not as pretty and easy to use as a data type, but it worked.

Xojo needs Int128, Uint128, BigCurrency AKA Currency128, Quad AKA float128

Rust’s i128 and u128 were in the Rust’s std lib in the past and now are primitive types.

bobs has been open sourced for a very long time

Xojo uses LLVM compiler. The LLVM engine has an Int128 type included as far as I know.

I didn’t see the source code on his page, just the compiled plug in. :slightly_frowning_face:

Yes it does, also has the fp128 “Quad”, there is a FR from 2015 to include them in Xojo but…

There also other request for the i128, the u128 and for Binary Coded Decimal, please. All of them ignored :expressionless:

1 Like