L4Re Operating System Framework
Interface and Usage Documentation
Toggle main menu visibility
Main Page
Related Pages
Topics
Namespaces
Namespace List
Namespace Members
All
a
b
c
d
h
i
k
m
o
p
r
s
t
u
w
Functions
a
b
c
k
m
r
s
t
w
Variables
Typedefs
Enumerations
Enumerator
Data Structures
Data Structures
Data Structure Index
Class Hierarchy
Data Fields
All
_
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
~
Functions
_
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
q
r
s
t
u
v
w
~
Variables
_
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
Typedefs
_
a
b
c
d
e
f
g
i
k
m
n
o
p
r
s
t
v
w
Enumerations
a
c
d
e
f
i
m
n
p
q
r
s
t
v
Enumerator
a
b
c
d
e
f
g
i
k
l
m
n
o
p
r
s
t
u
w
x
Related Symbols
Files
File List
Globals
All
_
a
b
d
e
f
g
l
m
n
o
p
r
s
Functions
_
b
e
f
g
l
o
p
Typedefs
e
g
l
p
Enumerations
e
l
p
Enumerator
a
d
e
f
l
n
p
r
s
Macros
_
e
g
l
m
p
s
Examples
•
All
Data Structures
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Modules
Pages
Loading...
Searching...
No Matches
std_alloc
1
// vi:set ft=cpp: -*- Mode: C++ -*-
2
/*
3
* (c) 2008-2009 Adam Lackorzynski <adam@os.inf.tu-dresden.de>,
4
* Alexander Warg <warg@os.inf.tu-dresden.de>
5
* economic rights: Technische Universität Dresden (Germany)
6
*
7
* License: see LICENSE.spdx (in this directory or the directories above)
8
*/
9
10
#pragma once
11
12
#include <stddef.h>
13
namespace
cxx
{
19
class
Nothrow
{};
20
}
21
28
inline
void
*
operator
new
(size_t,
void
*mem,
cxx::Nothrow
const
&)
noexcept
29
{
return
mem; }
28
inline
void
*
operator
new
(size_t,
void
*mem,
cxx::Nothrow
const
&)
noexcept
{
…
}
30
35
void
*
operator
new
(size_t,
cxx::Nothrow
const
&)
noexcept
;
36
42
void
operator
delete
(
void
*,
cxx::Nothrow
const
&)
noexcept
;
43
44
namespace
cxx
{
45
46
55
template
<
typename
_Type >
56
class
New_allocator
57
{
58
public
:
59
enum
{ can_free =
true
};
60
61
New_allocator
()
noexcept
{}
62
New_allocator
(
New_allocator
const
&)
noexcept
{}
63
64
~New_allocator
()
noexcept
{}
65
66
_Type *alloc()
noexcept
67
{
return
static_cast<
_Type*
>
(::operator
new
(
sizeof
(_Type),
cxx::Nothrow
())); }
68
69
void
free(_Type *t)
noexcept
70
{ ::operator
delete
(t,
cxx::Nothrow
()); }
71
};
56
class
New_allocator
{
…
};
72
73
}
74
cxx::New_allocator
Standard allocator based on operator new () .
Definition
std_alloc:57
cxx::Nothrow
Helper type to distinguish the operator new version that does not throw exceptions.
Definition
std_alloc:19
cxx
Our C++ library.
Definition
arith:11
l4
cxx
std_alloc
Generated on Mon Mar 3 2025 23:08:49 for L4Re Operating System Framework by
1.9.8