File: macros.h

package info (click to toggle)
pytorch-cluster 1.6.3-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 648 kB
  • sloc: cpp: 2,076; python: 1,081; sh: 53; makefile: 8
file content (21 lines) | stat: -rw-r--r-- 445 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
#pragma once

#ifdef _WIN32
#if defined(torchcluster_EXPORTS)
#define CLUSTER_API __declspec(dllexport)
#else
#define CLUSTER_API __declspec(dllimport)
#endif
#else
#define CLUSTER_API
#endif

#if (defined __cpp_inline_variables) || __cplusplus >= 201703L
#define CLUSTER_INLINE_VARIABLE inline
#else
#ifdef _MSC_VER
#define CLUSTER_INLINE_VARIABLE __declspec(selectany)
#else
#define CLUSTER_INLINE_VARIABLE __attribute__((weak))
#endif
#endif