don't attempt to garbage collect cells without formulae, closes #121

This commit is contained in:
Thomas Fussell 2017-02-25 08:54:38 -06:00
parent 4ed8dae49c
commit 9535f94e38

View File

@ -490,8 +490,11 @@ std::string cell::formula() const
void cell::clear_formula() void cell::clear_formula()
{ {
d_->formula_.clear(); if (has_formula())
worksheet().garbage_collect_formulae(); {
d_->formula_.clear();
worksheet().garbage_collect_formulae();
}
} }
void cell::error(const std::string &error) void cell::error(const std::string &error)