Skip to content

Build fails with MSVC 2017 #551

@andan342

Description

@andan342

We are trying to use Google Benchmark with our Visual Studio 2017 project. When compiling, the following errors:

... \test\output_test_helper.cc(206): error C2039: 'streampos': is not a member of 'std::basic_ios<char,std::char_traits<char>>'

also

... \test\output_test_helper.cc(210): error C2784: 'bool std::operator >(const std::pair<_Ty1,_Ty2> &,const std::pair<_Ty1,_Ty2> &)': could not deduce template argument for 'const std::pair<_Ty1,_Ty2> &' from 'std::fpos<_Mbstatet>'

Also the warnings:

... \include\benchmark/benchmark.h(645): warning C4141: 'inline': used more than once

Same for line 648, as the macro BENCHMARK_ALWAYS_INLINE expands to __forceinline.

Checked with STL versions 14.11.25503, 14.10.25008, as shipped with MS Visual Studio. It compiles fine with gcc on Linux though.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions