testsuite: Use posix_memalign on AIX for tsvc
[official-gcc.git] / gcc / cp / mapper-client.h
blob1983081090c13db1cf9b765f33044b4ff4c81c76
1 /* C++ modules. Experimental! -*- c++ -*-
2 Copyright (C) 2020-2021 Free Software Foundation, Inc.
3 Written by Nathan Sidwell <nathan@acm.org> while at FaceBook
5 This file is part of GCC.
7 GCC is free software; you can redistribute it and/or modify it
8 under the terms of the GNU General Public License as published by
9 the Free Software Foundation; either version 3, or (at your option)
10 any later version.
12 GCC is distributed in the hope that it will be useful, but
13 WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 General Public License for more details.
17 You should have received a copy of the GNU General Public License
18 along with GCC; see the file COPYING3. If not see
19 <http://www.gnu.org/licenses/>. */
21 /* Forward to the header in c++tools. */
23 #ifndef MAPPER_CLIENT_H
24 #define MAPPER_CLIENT_H 1
26 #include "cody.hh"
28 #ifndef HAVE_SIGHANDLER_T
29 typedef void (*sighandler_t) (int);
30 #endif
32 class module_client : public Cody::Client
34 pex_obj *pex = nullptr;
35 sighandler_t sigpipe = SIG_IGN;
36 Cody::Flags flags = Cody::Flags::None;
38 public:
39 module_client (Cody::Server *s)
40 : Client (s)
43 module_client (pex_obj *pex, int fd_from, int fd_to);
45 module_client (int fd_from, int fd_to)
46 : Client (fd_from, fd_to)
50 public:
51 Cody::Flags get_flags () const
53 return flags;
56 public:
57 static module_client *open_module_client (location_t loc, const char *option,
58 void (*set_repo) (const char *),
59 char const *);
60 static void close_module_client (location_t loc, module_client *);
63 #endif