Skip to content

[Caffe2] Error C2487 when building DLL. #10570

@xkszltl

Description

@xkszltl

Issue description

VS complains about C2487 if there're nested CAFFE2_API.

caffe2\core\operator_schema.h(269): error C2487: 'Arg_IsTest': member of dll interface class may not be declared with dll interface
caffe2\core\context_base.h(171): error C2487: 'static_context_': member of dll interface class may not be declared with dll interface
caffe2\core\context.h(209): error C2487: 'reporter_': member of dll interface class may not be declared with dll interface

System Info

  • PyTorch or Caffe2: C2
  • How you installed PyTorch (conda, pip, source): src
  • Build command you used (if compiling from source): cmake
  • OS: Win10
  • PyTorch version: master
  • VS version (if compiling from source): 2017
  • CMake version: 3.12

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