Last change
on this file since fa5e1aa5 was
11df881,
checked in by Andrew Beach <ajbeach@…>, 2 years ago
|
Updated documentation on pre-resolver passes, moving code to headers instead of uses. Note that some comments were just copied over, I don't know if they are accurate.
|
-
Property mode set to
100644
|
File size:
1.7 KB
|
Rev | Line | |
---|
[2bfc6b2] | 1 | // |
---|
| 2 | // Cforall Version 1.0.0 Copyright (C) 2018 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 | // |
---|
[11df881] | 7 | // FindSpecialDeclarations.h -- Find special declarations used in the compiler. |
---|
[2bfc6b2] | 8 | // |
---|
| 9 | // Author : Rob Schluntz |
---|
| 10 | // Created On : Thu Aug 30 09:49:02 2018 |
---|
[ce36b55] | 11 | // Last Modified By : Andrew Beach |
---|
| 12 | // Last Modified On : Wed Nov 10 15:16:00 2021 |
---|
| 13 | // Update Count : 3 |
---|
[2bfc6b2] | 14 | // |
---|
| 15 | |
---|
| 16 | #pragma once |
---|
| 17 | |
---|
| 18 | #include <list> // for list |
---|
| 19 | |
---|
| 20 | class Declaration; |
---|
| 21 | class FunctionDecl; |
---|
| 22 | class StructDecl; |
---|
| 23 | class Type; |
---|
| 24 | |
---|
[ce36b55] | 25 | namespace ast { |
---|
| 26 | class TranslationUnit; |
---|
| 27 | } |
---|
| 28 | |
---|
[2bfc6b2] | 29 | namespace Validate { |
---|
| 30 | /// size_t type - set when size_t typedef is seen. Useful in a few places, |
---|
| 31 | /// such as in determining array dimension type |
---|
| 32 | extern Type * SizeType; |
---|
| 33 | |
---|
| 34 | /// intrinsic dereference operator for unqualified types - set when *? function is seen in FindSpecialDeclarations. |
---|
| 35 | /// Useful for creating dereference ApplicationExprs without a full resolver pass. |
---|
| 36 | extern FunctionDecl * dereferenceOperator; |
---|
| 37 | |
---|
| 38 | /// special built-in functions and data structures necessary for destructor generation |
---|
| 39 | extern StructDecl * dtorStruct; |
---|
| 40 | extern FunctionDecl * dtorStructDestroy; |
---|
| 41 | |
---|
| 42 | /// find and remember some of the special declarations that are useful for generating code, so that they do not have to be discovered multiple times. |
---|
| 43 | void findSpecialDecls( std::list< Declaration * > & translationUnit ); |
---|
[ce36b55] | 44 | |
---|
[11df881] | 45 | /// Find and remember some of the special declarations that are useful for |
---|
[ce36b55] | 46 | /// generating code, so that they do not have to be discovered multiple times. |
---|
| 47 | void findGlobalDecls( ast::TranslationUnit & translationUnit ); |
---|
| 48 | |
---|
[2bfc6b2] | 49 | } // namespace Validate |
---|
| 50 | |
---|
| 51 | // Local Variables: // |
---|
| 52 | // tab-width: 4 // |
---|
| 53 | // mode: c++ // |
---|
| 54 | // compile-command: "make install" // |
---|
| 55 | // End: // |
---|
Note: See
TracBrowser
for help on using the repository browser.