Commit ec727016 authored by Pavel Samolysov's avatar Pavel Samolysov
Browse files

Fix the C2678 MSVC compilation error



MSVC 14.15 returns the C2678 error during a compilation of the
'tensorflow/core/kernels/data/scan_dataset_op.cc' unit:

C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.15.26726\include\xmemory(217):
error C2678: binary '*': no operator found which takes a left-hand
operand of type 'const _Iter' (or there is no acceptable conversion)
with
[
    _Iter=tensorflow::OpInputList::Iterator
]

.\tensorflow/core/framework/op_kernel.h(405):
note: could be 'const tensorflow::Tensor &tensorflow::OpArgIterator<tensorflow::OpInputList,
    const tensorflow::Tensor>::operator *(void)'

Two const operator functions: 'operator*() const' and 'operator->()
const', returning a const pointer or const reference respectively,
have been added to the 'OpArgIterator' template class.

Signed-off-by: default avatarPavel Samolysov <samolisov@gmail.com>
parent bef87d7c
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment