mirror of https://github.com/vitalif/openscad
Moved % modifier handling from node to nodedumper. This makes nodes with % operators use the existing cache instead of recalculating the object
parent
6a1d91dc76
commit
716d8a7ab3
|
@ -97,8 +97,6 @@ void AbstractNode::progress_report() const
|
|||
|
||||
std::ostream &operator<<(std::ostream &stream, const AbstractNode &node)
|
||||
{
|
||||
// FIXME: Don't use deep access to modinst members
|
||||
if (node.modinst->isBackground()) stream << "%";
|
||||
stream << node.toString();
|
||||
return stream;
|
||||
}
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
#include "nodedumper.h"
|
||||
#include "state.h"
|
||||
#include "module.h"
|
||||
|
||||
#include <string>
|
||||
#include <sstream>
|
||||
|
@ -47,6 +48,7 @@ std::string NodeDumper::dumpChildren(const AbstractNode &node)
|
|||
iter != this->visitedchildren[node.index()].end();
|
||||
iter++) {
|
||||
assert(isCached(**iter));
|
||||
if ((*iter)->modinst->isBackground()) dump << "%";
|
||||
dump << this->cache[**iter] << "\n";
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue