]> git.ipfire.org Git - thirdparty/gcc.git/blame - gcc/d/dmd/root/rmem.h
d: Merge upstream dmd 7132b3537
[thirdparty/gcc.git] / gcc / d / dmd / root / rmem.h
CommitLineData
b4c522fa 1
a3b38b77 2/* Copyright (C) 1999-2021 by The D Language Foundation, All Rights Reserved
b4c522fa
IB
3 * http://www.digitalmars.com
4 * Distributed under the Boost Software License, Version 1.0.
5 * http://www.boost.org/LICENSE_1_0.txt
6 * https://github.com/dlang/dmd/blob/master/src/dmd/root/rmem.h
7 */
8
9#pragma once
10
f59be8df 11#include "dsystem.h" // for size_t
b4c522fa
IB
12
13struct Mem
14{
15 Mem() { }
16
17 static char *xstrdup(const char *s);
f59be8df
IB
18 static void *xmalloc(size_t size);
19 static void *xcalloc(size_t size, size_t n);
20 static void *xrealloc(void *p, size_t size);
b4c522fa 21 static void xfree(void *p);
f59be8df 22 static void *xmallocdup(void *o, size_t size);
b4c522fa
IB
23 static void error();
24};
25
26extern Mem mem;