summaryrefslogtreecommitdiff
path: root/amount.cc
Commit message (Collapse)AuthorAgeFilesLines
* 'make check' is now working again. Also, conversion from amount_t to/fromJohn Wiegley2008-07-271-44/+9
| | | | | | | double has been disabled, because I am no longer packaging the gdtoa library with Ledger (because double conversion really has nothing to do with what Ledger does). If you wish to use it, you can find gdtoa in cpp-rewrite-2006, under a sub-directory of the same name.
* A large body of work to get the register report printing again, but stillJohn Wiegley2008-07-271-3/+9
| | | | fails due to the fact that 2.x value expression syntax is not restored.
* --verify works again, but the memory totals at the end still need work.John Wiegley2008-07-261-1/+1
|
* Parsing now works again. And there was much rejoicing.John Wiegley2008-07-241-9/+10
|
* More work toward getting the textual parser working again. Since this meansJohn Wiegley2008-07-241-0/+52
| | | | that value expressions must work, there are a lot of details involved.
* More work toward getting my ledger data to parse.John Wiegley2008-07-221-1/+1
|
* Re-enabled almost all of the code in main.cc.John Wiegley2008-07-201-0/+1
|
* Some basic fixes to get things almost running, although we still can't parseJohn Wiegley2008-07-191-0/+4
| | | | my personal ledger file yet.
* Merged in bug fixes from master (done for 2.6.1b)John Wiegley2008-07-191-1/+1
|\
| * If AMOUNT_PARSE_NO_MIGRATE is set, do not set a commodity's precision even ifJohn Wiegley2008-07-171-4/+3
| | | | | | | | | | | | this is the first time a commodity is being seen. The reason is that it's quite possible (especially in bug reports) for the cost of a priced transaction to contain the first occurrence of a commodity.
| * Removed unnecessary assert.John Wiegley2008-07-171-1/+0
| |
| * Added #include lines for building on Debian lenny.John Wiegley2008-07-131-1/+0
| |
| * Fix compile errors with gcc 4.3Nathan Jones2008-05-201-0/+1
| |
* | The code is compiling again, but it's far from being able to run yet.John Wiegley2008-05-081-1/+11
| |
* | Migrated over both code and build environment from was-v3.0 branch.John Wiegley2008-05-081-1535/+920
|/
* Fixes to the commodity comparison logic.John Wiegley2008-04-131-6/+8
|
* *** empty log message ***John Wiegley2008-04-131-1/+1
|
* Reworked the way date/times are handled.John Wiegley2008-04-131-25/+26
|
* Several fixes to lot price handling.John Wiegley2008-04-131-4/+9
|
* Further refinement of commodity lot information.John Wiegley2008-04-131-7/+71
|
* *** empty log message ***John Wiegley2008-04-131-0/+34
|
* *** empty log message ***John Wiegley2008-04-131-33/+44
|
* Tons of corrections and fixes to value expressions and lot figures.John Wiegley2008-04-131-4/+38
|
* *** empty log message ***John Wiegley2008-04-131-5/+24
|
* *** empty log message ***John Wiegley2008-04-131-0/+23
|
* *** empty log message ***John Wiegley2008-04-131-158/+109
|
* *** empty log message ***John Wiegley2008-04-131-1/+2
|
* Added --ansi and --ansi-invert options.John Wiegley2008-04-131-6/+6
|
* Added much better error location.John Wiegley2008-04-131-19/+30
|
* Added a DATETIME value type.John Wiegley2008-04-131-26/+32
|
* *** empty log message ***John Wiegley2008-04-131-16/+23
|
* *** empty log message ***John Wiegley2008-04-131-2/+6
|
* *** empty log message ***John Wiegley2008-04-131-97/+166
|
* Began support for improved commodity handling.John Wiegley2008-04-131-16/+45
|
* Began support for improved commodity handling.John Wiegley2008-04-131-158/+432
|
* (read_binary_journal): Fixed a tiny memory leak when reading from aJohn Wiegley2008-04-131-0/+177
| | | | binary cache.
* Checked in all major updates.John Wiegley2008-04-131-73/+115
|
* (amount_t::valid): Don't verify the commodity as being non-null, sinceJohn Wiegley2008-04-131-10/+14
| | | | | | NULL is a perfectly valid value for a commodity (it just means null_commodity). Also, never use commodity_->member, but always commodity().member.
* Removed Python integration support.John Wiegley2008-04-131-165/+0
|
* *** empty log message ***John Wiegley2008-04-131-2/+2
|
* Moved the setting of time quantities to the commodity initializationJohn Wiegley2008-04-131-0/+20
| | | | section.
* (amount_t::value): Corrected a problem with commodity rounding afterJohn Wiegley2008-04-131-8/+23
| | | | | | | | market values are determined (was using the wrong commodity's precision value). (commodity_t::value): Fixed the market value calculation algorithm, which was very broken (but only seemed to show up if the price history was very small).
* (find_commodity): Don't copy over the NOMARKET flag from the defaultJohn Wiegley2008-04-131-1/+2
| | | | commodity.
* (parse): Allow "-$100.00" as the equivalent of "$-100.00".John Wiegley2008-04-131-2/+12
|
* (amount_t::parse): Only set the SUFFIXED flag if there is actually aJohn Wiegley2008-04-131-1/+2
| | | | commodity symbol.
* (parse_conversion): When defining a commodity conversion, always markJohn Wiegley2008-04-131-1/+2
| | | | | the larger unit as having no market value (the market price is determined by looking up the base commodity and then multiplying).
* (value): Use `std::map<>::lower_bound' to search for the nearest priceJohn Wiegley2008-04-131-6/+11
| | | | | item in a commodity's history list. This is much more efficient than doing a reverse linear search.
* *** empty log message ***John Wiegley2008-04-131-4/+4
|
* (parse): A fix to the way commodity flags are applied to newly parsedJohn Wiegley2008-04-131-7/+26
| | | | | commodities. This was needing for an edge-case involving commodities that first appears as part of the cost (@ SPEC) of a transaction.
* Changes to support building with gcc 2.95.John Wiegley2008-04-131-0/+11
|