Fixed some #include ordering issues.
This commit is contained in:
parent
19a59079fa
commit
4a28e1765c
8 changed files with 18 additions and 21 deletions
|
|
@ -30,6 +30,7 @@
|
|||
*/
|
||||
|
||||
#include "amount.h"
|
||||
#include "commodity.h"
|
||||
|
||||
namespace ledger {
|
||||
|
||||
|
|
@ -661,6 +662,15 @@ bool amount_t::fits_in_long() const
|
|||
return mpfr_fits_slong_p(tempf, GMP_RNDN);
|
||||
}
|
||||
|
||||
commodity_t& amount_t::commodity() const
|
||||
{
|
||||
return has_commodity() ? *commodity_ : *current_pool->null_commodity;
|
||||
}
|
||||
|
||||
bool amount_t::has_commodity() const
|
||||
{
|
||||
return commodity_ && commodity_ != commodity_->parent().null_commodity;
|
||||
}
|
||||
|
||||
void amount_t::annotate(const annotation_t& details)
|
||||
{
|
||||
|
|
|
|||
14
src/amount.h
14
src/amount.h
|
|
@ -707,18 +707,4 @@ inline std::istream& operator>>(std::istream& in, amount_t& amt) {
|
|||
|
||||
} // namespace ledger
|
||||
|
||||
#include "commodity.h"
|
||||
|
||||
namespace ledger {
|
||||
|
||||
inline commodity_t& amount_t::commodity() const {
|
||||
return has_commodity() ? *commodity_ : *current_pool->null_commodity;
|
||||
}
|
||||
|
||||
inline bool amount_t::has_commodity() const {
|
||||
return commodity_ && commodity_ != commodity_->parent().null_commodity;
|
||||
}
|
||||
|
||||
} // namespace ledger
|
||||
|
||||
#endif // _AMOUNT_H
|
||||
|
|
|
|||
|
|
@ -49,7 +49,7 @@
|
|||
#ifndef _BALANCE_H
|
||||
#define _BALANCE_H
|
||||
|
||||
#include "amount.h"
|
||||
#include "commodity.h"
|
||||
|
||||
namespace ledger {
|
||||
|
||||
|
|
|
|||
|
|
@ -47,6 +47,8 @@
|
|||
#ifndef _COMMODITY_H
|
||||
#define _COMMODITY_H
|
||||
|
||||
#include "amount.h"
|
||||
|
||||
namespace ledger {
|
||||
|
||||
class keep_details_t;
|
||||
|
|
|
|||
|
|
@ -46,6 +46,8 @@
|
|||
#ifndef _FLAGS_H
|
||||
#define _FLAGS_H
|
||||
|
||||
#include "utils.h"
|
||||
|
||||
/**
|
||||
* @brief Brief
|
||||
*
|
||||
|
|
|
|||
|
|
@ -46,6 +46,8 @@
|
|||
#ifndef _HOOKS_H
|
||||
#define _HOOKS_H
|
||||
|
||||
#include "utils.h"
|
||||
|
||||
/**
|
||||
* @brief Brief
|
||||
*
|
||||
|
|
|
|||
|
|
@ -164,7 +164,7 @@ public:
|
|||
HANDLED(base));
|
||||
}
|
||||
|
||||
option_t<report_t> * report_t::lookup_option(const char * p);
|
||||
option_t<report_t> * lookup_option(const char * p);
|
||||
|
||||
virtual expr_t::ptr_op_t lookup(const string& name);
|
||||
|
||||
|
|
|
|||
|
|
@ -44,11 +44,6 @@
|
|||
#ifndef _UTILS_H
|
||||
#define _UTILS_H
|
||||
|
||||
#if defined(DEBUG_MODE)
|
||||
#define BOOST_MULTI_INDEX_ENABLE_SAFE_MODE 1
|
||||
#define BOOST_MULTI_INDEX_ENABLE_INVARIANT_CHECKING 1
|
||||
#endif
|
||||
|
||||
#include <system.hh>
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue