Commit Graph

36 Commits

Author SHA1 Message Date
Arthur Britto
dfd218c079 Optimize and fix STAmount. 2012-05-20 18:47:05 -07:00
Arthur Britto
7ce0a16d21 Fix another typo. 2012-05-19 18:38:48 -07:00
Arthur Britto
311ffd743b Fix typo in currencyFromString. 2012-05-19 18:22:13 -07:00
Arthur Britto
47b168c390 Merge branch 'pay' 2012-05-19 18:20:14 -07:00
Arthur Britto
82085f0264 Add string support for currencies to STAmount. 2012-05-19 18:16:13 -07:00
JoelKatz
353e598ad1 Flip the rate so that lower is better. 2012-05-19 06:04:37 -07:00
JoelKatz
bceeb15f84 Fix a few bugs and better comments. 2012-05-18 23:10:24 -07:00
JoelKatz
2ad0ec3d40 Tiny comment change. 2012-05-18 21:19:19 -07:00
JoelKatz
b773fbbc90 Bugfixes. 2012-05-18 19:13:01 -07:00
JoelKatz
73c10d76a5 Hook up unit tests. 2012-05-18 01:27:36 -07:00
JoelKatz
f9fadf1d71 Sorry to break the build. Boost unit testing code won't link. 2012-05-18 01:00:09 -07:00
JoelKatz
7019a46db1 Huge amount rewrite to support all currency types. 2012-05-17 23:45:13 -07:00
JoelKatz
f05b88d459 Change native coin functions to use uint64_t instead of STAmount. 2012-04-30 11:30:34 -07:00
JoelKatz
275d509d31 Small cleanups. 2012-04-24 18:03:12 -07:00
JoelKatz
a5e8afa228 Small cleanups. 2012-04-13 20:19:21 -07:00
JoelKatz
a3c0661451 A simplification. 2012-04-13 16:29:42 -07:00
JoelKatz
f5464e02b6 Unit test framework. 2012-04-12 23:41:32 -07:00
JoelKatz
498aba272f Fixes and cleanups. 2012-04-12 23:22:13 -07:00
JoelKatz
519a1c9a1d Native currency scaling. 2012-04-12 06:06:48 -07:00
JoelKatz
1c895a593d Sync. 2012-04-11 14:59:31 -07:00
JoelKatz
ded4d19a65 Optimize / operation. 2012-04-11 14:24:22 -07:00
JoelKatz
efd363538c Fix some special cases. Cleanup whitespace. 2012-04-11 12:32:41 -07:00
JoelKatz
dc8889668a Simplification. 2012-04-11 12:25:09 -07:00
JoelKatz
b771a11836 A 1/3 lsb offset is needed to make the multiplication round down correctly. 2012-04-11 00:27:49 -07:00
JoelKatz
48fe991cdb Rounding fix. 2012-04-10 17:00:40 -07:00
JoelKatz
e61ddb980e Off by one error. 2012-04-10 16:51:00 -07:00
JoelKatz
db2846547f Missed one special cast. 2012-04-10 16:47:17 -07:00
JoelKatz
c1cd616359 Always display these exactly. 2012-04-10 16:46:41 -07:00
JoelKatz
ce30701744 Code to compute how much you need to pay to get a particular output from an offer. 2012-04-10 16:04:28 -07:00
JoelKatz
6bf6d86cd9 Offer logic seems to be working now. 2012-04-10 15:26:44 -07:00
JoelKatz
22d3354ccc Typo. 2012-04-10 14:37:20 -07:00
JoelKatz
7ebd7a1845 Cleanups, add comments, some fixes. 2012-04-10 14:36:53 -07:00
JoelKatz
ad1ae6af23 Fix mishandling of zero values. Must add to unit test! 2012-04-10 13:22:16 -07:00
JoelKatz
b093110890 Fixes. 2012-04-10 13:11:20 -07:00
JoelKatz
005ea61f9b All currency operations except the three weirdest ones for exchanges. 2012-04-09 21:00:27 -07:00
JoelKatz
fcdf42e799 Promote 'amounts' to a new type. Codify storage format, both internal
and serialized. Define operators.
2012-04-09 19:36:51 -07:00