Skip to content

Commit 3c5ab26

Browse files
authored
Merge pull request tensorflow#3423 from Mistobaan/remove-warnings
Fix few warnings on macosx-clang compilation
2 parents 233af01 + 26d1296 commit 3c5ab26

File tree

5 files changed

+3
-8
lines changed

5 files changed

+3
-8
lines changed

tensorflow/core/common_runtime/optimization_registry.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ limitations under the License.
2727
#include "tensorflow/core/graph/graph.h"
2828

2929
namespace tensorflow {
30-
class SessionOptions;
30+
struct SessionOptions;
3131

3232
// All the parameters used by an optimization pass are packaged in
3333
// this struct. They should be enough for the optimization pass to use

tensorflow/core/common_runtime/simple_graph_execution_state.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ limitations under the License.
3535
#include "tensorflow/core/platform/types.h"
3636

3737
namespace tensorflow {
38-
class SessionOptions;
38+
struct SessionOptions;
3939
class StepStats;
4040
class Timeline;
4141

tensorflow/core/graph/gradients.cc

-2
Original file line numberDiff line numberDiff line change
@@ -35,8 +35,6 @@ namespace tensorflow {
3535
// TODO(andydavis) Remove some of the code duplicated between this module
3636
// and that in 'common_runtime/function.cc'.
3737
// A few string constant used throughout this module.
38-
static const char* const kArgOp = "_Arg";
39-
static const char* const kRetOp = "_Retval";
4038
static const char* const kGradientOp = "SymbolicGradient";
4139
static const char* const kNodeLabel = "Func";
4240

tensorflow/core/graph/graph.cc

-3
Original file line numberDiff line numberDiff line change
@@ -29,9 +29,6 @@ namespace tensorflow {
2929
// Node
3030

3131
string Node::DebugString() const {
32-
if (this == nullptr) {
33-
return "{nullptr}";
34-
}
3532
string ret = strings::StrCat("{name:'", name(), "' id:", id_);
3633
if (IsSource()) {
3734
strings::StrAppend(&ret, " source}");

tensorflow/core/kernels/lookup_table_init_op.cc

+1-1
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ class KeyValueTensorIterator
8080

8181
Status status() const override { return status_; }
8282

83-
int64 total_size() const {
83+
int64 total_size() const override {
8484
return keys_ == nullptr ? -1 : keys_->NumElements();
8585
}
8686

0 commit comments

Comments
 (0)