ReactOS
0.4.16-dev-927-g467dec4
Toggle main menu visibility
Main Page
Related Pages
Modules
Namespaces
Namespace List
Namespace Members
All
_
a
b
c
d
e
f
g
h
i
l
m
n
o
p
r
s
t
u
v
w
x
Functions
_
a
b
c
d
e
f
g
h
i
l
m
o
p
r
s
t
u
v
w
Variables
_
c
d
e
f
g
h
i
l
m
n
o
p
s
t
u
x
Typedefs
_
a
b
c
d
e
f
g
h
i
l
m
o
p
r
s
t
u
v
w
x
Enumerations
_
a
b
c
d
f
i
l
m
o
p
s
t
w
x
Enumerator
a
b
c
d
e
f
g
h
i
m
n
o
p
r
s
t
u
v
w
x
Classes
Class List
Class Index
Class Hierarchy
Class Members
All
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
~
Functions
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
~
Variables
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Typedefs
_
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Enumerations
_
a
b
c
d
e
f
h
i
k
l
m
n
o
p
r
s
t
u
v
w
z
Enumerator
_
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Properties
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
z
Related Functions
_
a
b
c
d
e
f
g
h
i
l
m
n
o
p
q
r
s
t
v
x
Files
File List
File Members
All
$
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Functions
$
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Variables
$
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Typedefs
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Enumerations
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Enumerator
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Macros
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Examples
shared_initialization.cpp
Go to the documentation of this file.
1
//
2
// shared_initialization.cpp
3
//
4
// Copyright (c) Microsoft Corporation. All rights reserved.
5
//
6
// Shared initialization logic used by both the AppCRT and the DesktopCRT.
7
//
8
#include <
corecrt_internal.h
>
9
10
extern
"C"
bool
__cdecl
__acrt_execute_initializers
(
11
__acrt_initializer
const
*
const
first
,
12
__acrt_initializer
const
*
const
last
13
)
14
{
15
if
(
first
==
last
)
16
return
true
;
17
18
// Execute the initializers in [first, last), in order:
19
__acrt_initializer
const
* it =
first
;
20
for
(; it !=
last
; ++it)
21
{
22
if
(it->
_initialize
==
nullptr
)
23
continue
;
24
25
if
(!(it->
_initialize
)())
26
break
;
27
}
28
29
// If we reached the end, all initializers completed successfully:
30
if
(it ==
last
)
31
return
true
;
32
33
// Otherwise, the initializer pointed to by it failed. We need to roll back
34
// the initialization by executing the uninitializers corresponding to each
35
// of the initializers that completed successfully:
36
for
(; it !=
first
; --it)
37
{
38
// During initialization roll back, we do not execute uninitializers
39
// that have no corresponding initializer:
40
if
((it - 1)->_initialize ==
nullptr
|| (it - 1)->_uninitialize ==
nullptr
)
41
continue
;
42
43
(it - 1)->_uninitialize(
false
);
44
}
45
46
return
false
;
47
}
48
49
extern
"C"
bool
__cdecl
__acrt_execute_uninitializers
(
50
__acrt_initializer
const
*
const
first
,
51
__acrt_initializer
const
*
const
last
52
)
53
{
54
if
(
first
==
last
)
55
return
true
;
56
57
// Execute the uninitializers in [first, last), in reverse order:
58
for
(
__acrt_initializer
const
* it =
last
; it !=
first
; --it)
59
{
60
if
((it - 1)->_uninitialize ==
nullptr
)
61
continue
;
62
63
(it - 1)->_uninitialize(
false
);
64
}
65
66
return
true
;
67
}
__cdecl
#define __cdecl
Definition:
accygwin.h:79
corecrt_internal.h
first
const GLint * first
Definition:
glext.h:5794
last
static UINT UINT last
Definition:
font.c:45
__acrt_execute_uninitializers
bool __cdecl __acrt_execute_uninitializers(__acrt_initializer const *const first, __acrt_initializer const *const last)
Definition:
shared_initialization.cpp:49
__acrt_execute_initializers
bool __cdecl __acrt_execute_initializers(__acrt_initializer const *const first, __acrt_initializer const *const last)
Definition:
shared_initialization.cpp:10
__acrt_initializer
Definition:
corecrt_internal.h:318
__acrt_initializer::_initialize
__acrt_initialize_pft _initialize
Definition:
corecrt_internal.h:319
sdk
lib
ucrt
internal
shared_initialization.cpp
Generated on Sun Mar 30 2025 06:14:50 for ReactOS by
1.9.6