Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Prefix name reorg #224

Merged
merged 2 commits into from
Jun 3, 2015
Merged

Conversation

alexvandesande
Copy link

Every other week someone comes to us and ask why we don’t stick to SI units. Sure, no one remembers which is supposed to be babbage, but what’s the deal with Kwei with a uppercase K, kilo doesn’t start with uppercase! Why are unit names written in full but prefixes just the letter? It’s not Mbyte or mliter, it’s either the Megabyte or the ml. And grand, really? It’s not a SI unit it’s a number.

I always say that unit names are just suggestions and we should only use ether and wei, but in practice that doesn’t work.

Most things are in ether. Gas prices are usually in finney or szabo. Basic functions are in wei.

Then it dawns on me that the only that actually matter are ether, finney and szabo, and they have a direct 1000 relationship. Here’s a nice mnemonic: they’re the micro and the mili. A Finney is a mili-ether, szabo is the micro-ether. Ether, mili, micro. Now I usually don’t memorize the micro but since I’m having to remember the szabo anyway, why not the micro-?

So I did some cosmetic changes, made the comments clearer on this, and added support for SI prefixes femto-, pico-, nano-, micro- and mili-

Just giving developers more choice, since so many of them asked for this

@alexvandesande alexvandesande added the Enhancement Includes improvements or optimizations label May 28, 2015
@kumavis
Copy link
Contributor

kumavis commented May 28, 2015

I need 200 mic'roethers, stat!

@coveralls
Copy link

Coverage Status

Coverage remained the same at 94.91% when pulling 5866f08 on alexvandesande:prefix-name-reorg into 3bb6e4f on ethereum:develop.

@alexvandesande
Copy link
Author

a szabo is a micro-ether. A thousand szabo make a finney, which is a milliether. Which one you prefer to use is a matter of personal preference which could be left to the final user.

frozeman added a commit that referenced this pull request Jun 3, 2015
@frozeman frozeman merged commit 61f1ba6 into web3:develop Jun 3, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Enhancement Includes improvements or optimizations
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants