libantioch/antioch — pull request #67 by SylvainPlessis (2014-06-27 15:59:38+00:00)
Title: Bugfixes:

- unit_store: the "g" case is properly taken into account
- units: fill_in_power uses develop_symbol before calculations
=> no more develop_symbol needed before calling it
- units: some cleaning: indexUnit no more needed
- unit_unit: added the test [E] = [m] + [c] + [c] has to be homogeneous to Joules

It looks big, but the changes are small, most of the changes are spaces and line returns added for readability purposes.

The changes are:
unit_store.h line 151
```
return (symb == "g")?map_store.at("kg"): //special case for gram
(map_store.count(symb))?map_store.at(symb):-1;
```

the case of the gram unit is taken care of here instead of units.h, in units.h line 805 is the rescaling in response of the fact that the kilo prefixes is counted anyway so it has to be deleted.

Then line151 and 232 changes are the `count()` method instead of a `find()` method to test if the requested element is indeed in the map.

units.h and unit_unit.C comments are pretty explicit, with `std::cerr` used instead of `std::cout` when proper.