Mercurial > projects > ldc
annotate dmd2/aliasthis.h @ 1650:40bd4a0d4870
Update to work with LLVM 2.7.
Removed use of dyn_cast, llvm no compiles
without exceptions and rtti by
default. We do need exceptions for the libconfig stuff, but rtti isn't
necessary (anymore).
Debug info needs to be rewritten, as in LLVM 2.7 the format has
completely changed. To have something to look at while rewriting, the
old code has been wrapped inside #ifndef DISABLE_DEBUG_INFO , this means
that you have to define this to compile at the moment.
Updated tango 0.99.9 patch to include updated EH runtime code, which is
needed for LLVM 2.7 as well.
author | Tomas Lindquist Olsen |
---|---|
date | Wed, 19 May 2010 12:42:32 +0200 |
parents | 638d16625da2 |
children |
rev | line source |
---|---|
1452
638d16625da2
LDC 2 compiles again.
Robert Clipsham <robert@octarineparrot.com>
parents:
diff
changeset
|
1 |
638d16625da2
LDC 2 compiles again.
Robert Clipsham <robert@octarineparrot.com>
parents:
diff
changeset
|
2 // Compiler implementation of the D programming language |
638d16625da2
LDC 2 compiles again.
Robert Clipsham <robert@octarineparrot.com>
parents:
diff
changeset
|
3 // Copyright (c) 2009-2009 by Digital Mars |
638d16625da2
LDC 2 compiles again.
Robert Clipsham <robert@octarineparrot.com>
parents:
diff
changeset
|
4 // All Rights Reserved |
638d16625da2
LDC 2 compiles again.
Robert Clipsham <robert@octarineparrot.com>
parents:
diff
changeset
|
5 // written by Walter Bright |
638d16625da2
LDC 2 compiles again.
Robert Clipsham <robert@octarineparrot.com>
parents:
diff
changeset
|
6 // http://www.digitalmars.com |
638d16625da2
LDC 2 compiles again.
Robert Clipsham <robert@octarineparrot.com>
parents:
diff
changeset
|
7 // License for redistribution is by either the Artistic License |
638d16625da2
LDC 2 compiles again.
Robert Clipsham <robert@octarineparrot.com>
parents:
diff
changeset
|
8 // in artistic.txt, or the GNU General Public License in gnu.txt. |
638d16625da2
LDC 2 compiles again.
Robert Clipsham <robert@octarineparrot.com>
parents:
diff
changeset
|
9 // See the included readme.txt for details. |
638d16625da2
LDC 2 compiles again.
Robert Clipsham <robert@octarineparrot.com>
parents:
diff
changeset
|
10 |
638d16625da2
LDC 2 compiles again.
Robert Clipsham <robert@octarineparrot.com>
parents:
diff
changeset
|
11 #ifndef DMD_ALIASTHIS_H |
638d16625da2
LDC 2 compiles again.
Robert Clipsham <robert@octarineparrot.com>
parents:
diff
changeset
|
12 #define DMD_ALIASTHIS_H |
638d16625da2
LDC 2 compiles again.
Robert Clipsham <robert@octarineparrot.com>
parents:
diff
changeset
|
13 |
638d16625da2
LDC 2 compiles again.
Robert Clipsham <robert@octarineparrot.com>
parents:
diff
changeset
|
14 #ifdef __DMC__ |
638d16625da2
LDC 2 compiles again.
Robert Clipsham <robert@octarineparrot.com>
parents:
diff
changeset
|
15 #pragma once |
638d16625da2
LDC 2 compiles again.
Robert Clipsham <robert@octarineparrot.com>
parents:
diff
changeset
|
16 #endif /* __DMC__ */ |
638d16625da2
LDC 2 compiles again.
Robert Clipsham <robert@octarineparrot.com>
parents:
diff
changeset
|
17 |
638d16625da2
LDC 2 compiles again.
Robert Clipsham <robert@octarineparrot.com>
parents:
diff
changeset
|
18 #include "mars.h" |
638d16625da2
LDC 2 compiles again.
Robert Clipsham <robert@octarineparrot.com>
parents:
diff
changeset
|
19 #include "dsymbol.h" |
638d16625da2
LDC 2 compiles again.
Robert Clipsham <robert@octarineparrot.com>
parents:
diff
changeset
|
20 |
638d16625da2
LDC 2 compiles again.
Robert Clipsham <robert@octarineparrot.com>
parents:
diff
changeset
|
21 /**************************************************************/ |
638d16625da2
LDC 2 compiles again.
Robert Clipsham <robert@octarineparrot.com>
parents:
diff
changeset
|
22 |
638d16625da2
LDC 2 compiles again.
Robert Clipsham <robert@octarineparrot.com>
parents:
diff
changeset
|
23 #if DMDV2 |
638d16625da2
LDC 2 compiles again.
Robert Clipsham <robert@octarineparrot.com>
parents:
diff
changeset
|
24 |
638d16625da2
LDC 2 compiles again.
Robert Clipsham <robert@octarineparrot.com>
parents:
diff
changeset
|
25 struct AliasThis : Dsymbol |
638d16625da2
LDC 2 compiles again.
Robert Clipsham <robert@octarineparrot.com>
parents:
diff
changeset
|
26 { |
638d16625da2
LDC 2 compiles again.
Robert Clipsham <robert@octarineparrot.com>
parents:
diff
changeset
|
27 // alias Identifier this; |
638d16625da2
LDC 2 compiles again.
Robert Clipsham <robert@octarineparrot.com>
parents:
diff
changeset
|
28 Identifier *ident; |
638d16625da2
LDC 2 compiles again.
Robert Clipsham <robert@octarineparrot.com>
parents:
diff
changeset
|
29 |
638d16625da2
LDC 2 compiles again.
Robert Clipsham <robert@octarineparrot.com>
parents:
diff
changeset
|
30 AliasThis(Loc loc, Identifier *ident); |
638d16625da2
LDC 2 compiles again.
Robert Clipsham <robert@octarineparrot.com>
parents:
diff
changeset
|
31 |
638d16625da2
LDC 2 compiles again.
Robert Clipsham <robert@octarineparrot.com>
parents:
diff
changeset
|
32 Dsymbol *syntaxCopy(Dsymbol *); |
638d16625da2
LDC 2 compiles again.
Robert Clipsham <robert@octarineparrot.com>
parents:
diff
changeset
|
33 void semantic(Scope *sc); |
638d16625da2
LDC 2 compiles again.
Robert Clipsham <robert@octarineparrot.com>
parents:
diff
changeset
|
34 const char *kind(); |
638d16625da2
LDC 2 compiles again.
Robert Clipsham <robert@octarineparrot.com>
parents:
diff
changeset
|
35 void toCBuffer(OutBuffer *buf, HdrGenState *hgs); |
638d16625da2
LDC 2 compiles again.
Robert Clipsham <robert@octarineparrot.com>
parents:
diff
changeset
|
36 AliasThis *isAliasThis() { return this; } |
638d16625da2
LDC 2 compiles again.
Robert Clipsham <robert@octarineparrot.com>
parents:
diff
changeset
|
37 }; |
638d16625da2
LDC 2 compiles again.
Robert Clipsham <robert@octarineparrot.com>
parents:
diff
changeset
|
38 |
638d16625da2
LDC 2 compiles again.
Robert Clipsham <robert@octarineparrot.com>
parents:
diff
changeset
|
39 #endif |
638d16625da2
LDC 2 compiles again.
Robert Clipsham <robert@octarineparrot.com>
parents:
diff
changeset
|
40 |
638d16625da2
LDC 2 compiles again.
Robert Clipsham <robert@octarineparrot.com>
parents:
diff
changeset
|
41 #endif |