DebugServer2
Loading...
Searching...
No Matches
ProcessDecl.h
1//
2// Copyright (c) 2014-present, Facebook, Inc.
3// All rights reserved.
4//
5// This source code is licensed under the University of Illinois/NCSA Open
6// Source License found in the LICENSE file in the root directory of this
7// source tree. An additional grant of patent rights can be found in the
8// PATENTS file in the same directory.
9//
10
11#pragma once
12
13#include "DebugServer2/Types.h"
14
15#define __FORWARD_DECLARE(TARGET, NAME) \
16 namespace TARGET { \
17 class NAME; \
18 } \
19 using TARGET::NAME
20
21namespace ds2 {
22namespace Target {
23
24class ProcessBase;
25
26#if defined(OS_LINUX)
27__FORWARD_DECLARE(Linux, Process);
28__FORWARD_DECLARE(Linux, Thread);
29#elif defined(OS_WIN32)
30__FORWARD_DECLARE(Windows, Process);
31__FORWARD_DECLARE(Windows, Thread);
32#elif defined(OS_FREEBSD)
33__FORWARD_DECLARE(FreeBSD, Process);
34__FORWARD_DECLARE(FreeBSD, Thread);
35#elif defined(OS_DARWIN)
36__FORWARD_DECLARE(Darwin, Process);
37__FORWARD_DECLARE(Darwin, Thread);
38#else
39#error "Target not supported."
40#endif
41} // namespace Target
42} // namespace ds2
43
44#undef __FORWARD_DECLARE