ADTaaron-thesisarm-ehast-experimentalcleanup-dtorsdeferred_resndemanglerenumforall-pointer-decayjacob/cs343-translationjenkins-sandboxnew-astnew-ast-unique-exprnew-envno_listpersistent-indexerpthread-emulationqualifiedEnumresolv-newwith_gc
Last change
on this file since d78f4c0 was
9e2c1f0,
checked in by Rob Schluntz <rschlunt@…>, 8 years ago
|
Merge branch 'global-init' into ctor and add global destroy function to call destructors on global objects
Conflicts:
src/CodeGen/CodeGenerator.cc
src/InitTweak/module.mk
src/Makefile.in
src/SynTree/Declaration.h
src/SynTree/FunctionDecl.cc
src/main.cc
|
-
Property mode set to
100644
|
File size:
1.3 KB
|
Line | |
---|
1 | // |
---|
2 | // Cforall Version 1.0.0 Copyright (C) 2015 University of Waterloo |
---|
3 | // |
---|
4 | // The contents of this file are covered under the licence agreement in the |
---|
5 | // file "LICENCE" distributed with Cforall. |
---|
6 | // |
---|
7 | // FixGlobalInit.h -- |
---|
8 | // |
---|
9 | // Author : Rob Schluntz |
---|
10 | // Created On : Mon May 04 15:14:56 2016 |
---|
11 | // Last Modified By : Rob Schluntz |
---|
12 | // Last Modified On : Fri May 06 16:07:47 2016 |
---|
13 | // Update Count : 2 |
---|
14 | // |
---|
15 | |
---|
16 | #ifndef FIX_GLOBAL_INIT_H |
---|
17 | #define FIX_GLOBAL_INIT_H |
---|
18 | |
---|
19 | #include <string> |
---|
20 | #include <list> |
---|
21 | |
---|
22 | #include "SynTree/SynTree.h" |
---|
23 | #include "SynTree/Declaration.h" |
---|
24 | |
---|
25 | namespace InitTweak { |
---|
26 | /// Moves global initialization into an _init function that is unique to the translation unit. |
---|
27 | /// Sets the priority of the initialization function depending on whether the initialization |
---|
28 | /// function is for library code. |
---|
29 | void fixGlobalInit( std::list< Declaration * > & translationUnit, const std::string & name, bool inLibrary ); |
---|
30 | |
---|
31 | /// Apply transformations to a file name to get a valid C identifier which will be used as |
---|
32 | /// the name of the generated initializer function. |
---|
33 | std::string globalFunctionName( const std::string & name ); |
---|
34 | } // namespace |
---|
35 | |
---|
36 | #endif // GENPOLY_POLYMUTATOR_H |
---|
37 | |
---|
38 | // Local Variables: // |
---|
39 | // tab-width: 4 // |
---|
40 | // mode: c++ // |
---|
41 | // compile-command: "make install" // |
---|
42 | // End: // |
---|
Note: See
TracBrowser
for help on using the repository browser.