mirror of https://gitee.com/bigwinds/arangodb
fix compile warnings about operator<< (#8456)
This commit is contained in:
parent
57da3a538b
commit
5dbd67c8fd
|
@ -0,0 +1,46 @@
|
|||
////////////////////////////////////////////////////////////////////////////////
|
||||
/// DISCLAIMER
|
||||
///
|
||||
/// Copyright 2018-2018 ArangoDB GmbH, Cologne, Germany
|
||||
///
|
||||
/// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
/// you may not use this file except in compliance with the License.
|
||||
/// You may obtain a copy of the License at
|
||||
///
|
||||
/// http://www.apache.org/licenses/LICENSE-2.0
|
||||
///
|
||||
/// Unless required by applicable law or agreed to in writing, software
|
||||
/// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
/// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
/// See the License for the specific language governing permissions and
|
||||
/// limitations under the License.
|
||||
///
|
||||
/// Copyright holder is ArangoDB GmbH, Cologne, Germany
|
||||
///
|
||||
/// @author Jan Steemann
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#include "ExecutionState.h"
|
||||
|
||||
#include <ostream>
|
||||
|
||||
namespace arangodb {
|
||||
namespace aql {
|
||||
|
||||
std::ostream& operator<<(std::ostream& ostream, ExecutionState state) {
|
||||
switch (state) {
|
||||
case ExecutionState::DONE:
|
||||
ostream << "DONE";
|
||||
break;
|
||||
case ExecutionState::HASMORE:
|
||||
ostream << "HASMORE";
|
||||
break;
|
||||
case ExecutionState::WAITING:
|
||||
ostream << "WAITING";
|
||||
break;
|
||||
}
|
||||
return ostream;
|
||||
}
|
||||
|
||||
} // namespace aql
|
||||
} // namespace arangodb
|
|
@ -23,7 +23,7 @@
|
|||
#ifndef ARANGOD_AQL_EXECUTION_STATE_H
|
||||
#define ARANGOD_AQL_EXECUTION_STATE_H 1
|
||||
|
||||
#include <ostream>
|
||||
#include <iosfwd>
|
||||
|
||||
namespace arangodb {
|
||||
namespace aql {
|
||||
|
@ -42,20 +42,7 @@ enum class ExecutionState {
|
|||
WAITING
|
||||
};
|
||||
|
||||
inline std::ostream& operator<<(std::ostream& ostream, ExecutionState state) {
|
||||
switch (state) {
|
||||
case ExecutionState::DONE:
|
||||
ostream << "DONE";
|
||||
break;
|
||||
case ExecutionState::HASMORE:
|
||||
ostream << "HASMORE";
|
||||
break;
|
||||
case ExecutionState::WAITING:
|
||||
ostream << "WAITING";
|
||||
break;
|
||||
}
|
||||
return ostream;
|
||||
}
|
||||
std::ostream& operator<<(std::ostream& ostream, ExecutionState state);
|
||||
|
||||
} // namespace aql
|
||||
} // namespace arangodb
|
||||
|
|
|
@ -30,6 +30,8 @@
|
|||
#include "Basics/StaticStrings.h"
|
||||
#include "Basics/VelocyPackHelper.h"
|
||||
|
||||
#include <ostream>
|
||||
|
||||
namespace {
|
||||
std::string const TypeIllegal("illegal");
|
||||
std::string const TypeNone("none");
|
||||
|
|
|
@ -24,7 +24,7 @@
|
|||
#ifndef ARANGOD_AQL_INDEX_HINT_H
|
||||
#define ARANGOD_AQL_INDEX_HINT_H 1
|
||||
|
||||
#include <iostream>
|
||||
#include <iosfwd>
|
||||
|
||||
#include <velocypack/Builder.h>
|
||||
#include <velocypack/Slice.h>
|
||||
|
|
|
@ -214,6 +214,7 @@ SET(ARANGOD_SOURCES
|
|||
Aql/ExecutionEngine.cpp
|
||||
Aql/ExecutionNode.cpp
|
||||
Aql/ExecutionPlan.cpp
|
||||
Aql/ExecutionState.cpp
|
||||
Aql/ExecutionStats.cpp
|
||||
Aql/ExecutorExpressionContext.cpp
|
||||
Aql/ExecutorInfos.cpp
|
||||
|
|
Loading…
Reference in New Issue