1
0
mirror of https://github.com/mariadb-corporation/mariadb-columnstore-engine.git synced 2025-07-29 08:21:15 +03:00

Reformat all code to coding standard

This commit is contained in:
Andrew Hutchings
2017-10-26 17:18:17 +01:00
parent 4985f3456e
commit 01446d1e22
1296 changed files with 403852 additions and 353747 deletions

View File

@ -33,39 +33,44 @@
#include "objectreader.h"
using namespace std;
namespace execplan{
namespace execplan
{
/**
* Constructors/Destructors
*/
TreeNode::TreeNode(): fDerivedTable(""),
fRefCount(0),
fDerivedRefCol(NULL)
{ memset(tmp, 0, 312); }
fRefCount(0),
fDerivedRefCol(NULL)
{
memset(tmp, 0, 312);
}
TreeNode::TreeNode(const TreeNode& rhs):
fResult(rhs.fResult),
fResultType(rhs.resultType()),
fOperationType(rhs.operationType()),
fRegex (rhs.regex()),
fDerivedTable (rhs.derivedTable()),
fRefCount(rhs.refCount()),
fDerivedRefCol(rhs.derivedRefCol())
{ memcpy(tmp, rhs.tmp, 312); }
fResult(rhs.fResult),
fResultType(rhs.resultType()),
fOperationType(rhs.operationType()),
fRegex (rhs.regex()),
fDerivedTable (rhs.derivedTable()),
fRefCount(rhs.refCount()),
fDerivedRefCol(rhs.derivedRefCol())
{
memcpy(tmp, rhs.tmp, 312);
}
TreeNode::~TreeNode() {}
void TreeNode::resultType ( const execplan::CalpontSystemCatalog::ColType& resultType)
{
fResultType = resultType;
fResultType = resultType;
// set scale/precision for the result
if (fResultType.colDataType == execplan::CalpontSystemCatalog::DECIMAL ||
fResultType.colDataType == execplan::CalpontSystemCatalog::UDECIMAL)
{
fResult.decimalVal.scale = fResultType.scale;
fResult.decimalVal.precision = fResultType.precision;
}
// set scale/precision for the result
if (fResultType.colDataType == execplan::CalpontSystemCatalog::DECIMAL ||
fResultType.colDataType == execplan::CalpontSystemCatalog::UDECIMAL)
{
fResult.decimalVal.scale = fResultType.scale;
fResult.decimalVal.precision = fResultType.precision;
}
}
/**
@ -73,8 +78,8 @@ void TreeNode::resultType ( const execplan::CalpontSystemCatalog::ColType& resul
*/
ostream& operator<<(ostream& output, const TreeNode& rhs)
{
output << rhs.toString();
return output;
output << rhs.toString();
return output;
}
} /* namespace */