diff options
author | Simon Pilgrim <llvm-dev@redking.me.uk> | 2022-10-31 12:01:06 +0000 |
---|---|---|
committer | Simon Pilgrim <llvm-dev@redking.me.uk> | 2022-10-31 12:01:06 +0000 |
commit | 66b830889d9bc4bfc58aa1ea47d1b3a7cbee7c5c (patch) | |
tree | 29067a04c6640a494745047659168bf762e3d0ee | |
parent | a784de783af5096e593c5e214c2c78215fe303f5 (diff) | |
download | llvm-66b830889d9bc4bfc58aa1ea47d1b3a7cbee7c5c.zip llvm-66b830889d9bc4bfc58aa1ea47d1b3a7cbee7c5c.tar.gz llvm-66b830889d9bc4bfc58aa1ea47d1b3a7cbee7c5c.tar.bz2 |
Add explicit cast to fix MSVC error: "'return': cannot convert from 'int (__cdecl *)(int)' to '`anonymous-namespace'::Plus1FunctionRef::FuncT'"
-rw-r--r-- | llvm/unittests/ADT/MappedIteratorTest.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/unittests/ADT/MappedIteratorTest.cpp b/llvm/unittests/ADT/MappedIteratorTest.cpp index ca54cb3..f2858bd 100644 --- a/llvm/unittests/ADT/MappedIteratorTest.cpp +++ b/llvm/unittests/ADT/MappedIteratorTest.cpp @@ -34,7 +34,7 @@ struct Plus1FunctionRef { using FuncT = int (&)(int); - FuncT operator()() const { return *plus1; } + FuncT operator()() const { return (FuncT)*plus1; } }; struct Plus1FunctionPtr { |