Sebastian Redl
9c33e96813
Fix typo in index operator overloading.
...
llvm-svn: 60483
2008-12-03 16:32:40 +00:00
Anders Carlsson
6a113d9ddb
If a global var decl has an initializer, make sure to always set its linkage to external.
...
llvm-svn: 60462
2008-12-03 05:51:23 +00:00
Ted Kremenek
73a4d28758
PTH:
...
Use an array instead of a DenseMap to cache persistent IDs -> IdentifierInfo*. This leads to a 4% speedup at -fsyntax-only using PTH.
llvm-svn: 60452
2008-12-03 01:16:39 +00:00
Steve Naroff
f326f4056e
More support for rewriting property getter/setters.
...
llvm-svn: 60450
2008-12-03 00:56:33 +00:00
Ted Kremenek
e1fc020e65
Update Xcode project.
...
llvm-svn: 60448
2008-12-03 00:38:43 +00:00
Ted Kremenek
33eeabda61
- Remove PTHManager.cpp. Move all of its functions to PTHLexer.cpp since some of the internal methods are used by PTHLexer (their implementations are intertwined.) This enables some important inlining opportunities at -O3.
...
- Don't construct an std::vector<Token> prior to feeding PTH tokens to the Preprocessor. Stream them off the PTH file directly.
llvm-svn: 60447
2008-12-03 00:38:03 +00:00
Sebastian Redl
d6d55eeef5
Correct pretty printing of array new expressions.
...
llvm-svn: 60444
2008-12-02 22:08:59 +00:00
Ted Kremenek
d328da1b65
Update Xcode project.
...
llvm-svn: 60441
2008-12-02 20:16:22 +00:00
Ted Kremenek
da4d9dfbca
Add "-token-cache" option for using pretokenized cache files.
...
llvm-svn: 60440
2008-12-02 19:57:31 +00:00
Ted Kremenek
af058b5696
Preprocessor:
...
- Added method "setPTHManager" that will be called by the driver to install
a PTHManager for the Preprocessor.
- Fixed some comments.
- Added EnterSourceFileWithPTH to mirror EnterSourceFileWithLexer.
llvm-svn: 60437
2008-12-02 19:46:31 +00:00
Ted Kremenek
498b6210fc
Added PTHManager, a utility class that will be used by Preprocessor to lazily create PTHLexer objects for pre-tokenized files.
...
llvm-svn: 60436
2008-12-02 19:45:05 +00:00
Ted Kremenek
ccaab17e2c
PTH emission:
...
- Output 32 bit integers using bit-shifting + write of individual bytes.
This is motivated because we aren't guaranteed to load 32-bit ints of the mmaped PTH file at 4-byte offsets.
- Don't emit flags for IdentifierInfos. These are lazily populated by the Preprocessor/Parser.
- Only write out tokens for files with absolute paths. This is potentially temporary, but simplifies things for now.
llvm-svn: 60435
2008-12-02 19:44:08 +00:00
Fariborz Jahanian
eae373ea32
More type-checking of setter/getter methods. This is still
...
work in prgress.
llvm-svn: 60430
2008-12-02 18:39:49 +00:00
Nuno Lopes
48b5a33826
llvm-ld doesnt support '-g', so aovid passing that opt to it
...
llvm-svn: 60428
2008-12-02 18:19:03 +00:00
Steve Naroff
0629704e78
Add a couple FIXME's.
...
llvm-svn: 60427
2008-12-02 17:54:50 +00:00
Steve Naroff
c038b3af03
Make sure synthesized properties get inserted into the classes/categories meta data.
...
llvm-svn: 60426
2008-12-02 17:36:43 +00:00
Sebastian Redl
5c6ebcc198
Parsing new and delete is now complete.
...
llvm-svn: 60425
2008-12-02 17:22:40 +00:00
Sebastian Redl
538787f571
Add better comments to ::new parsing. Thanks to Doug for the review.
...
llvm-svn: 60423
2008-12-02 17:10:24 +00:00
Sebastian Redl
6ef75e9ee8
Make RegionStoreManager::InitializeArray safe against array sizes that don't have pointer width.
...
This may be the case on 64-bit systems. Whether that fact is a bug is a different question, but it's easy to cure the symptom.
llvm-svn: 60422
2008-12-02 16:47:35 +00:00
Sebastian Redl
db36b9b962
Make the parser handle ::new and ::delete correctly.
...
llvm-svn: 60421
2008-12-02 16:35:44 +00:00
Sebastian Redl
fb5df7235a
int-arith-convert.c makes assumptions about integer sizes, so force a specific architecture
...
llvm-svn: 60420
2008-12-02 16:34:01 +00:00
Eli Friedman
39bc53593d
Update cmake build; patch by Csaba Hruska.
...
llvm-svn: 60418
2008-12-02 16:23:30 +00:00
Steve Naroff
003d00eea3
Simplify previous commit.
...
llvm-svn: 60416
2008-12-02 16:05:55 +00:00
Eli Friedman
e918435f94
Fix for PR3150: obvious copy-paste bug in
...
ScalarExprEmitter::VisitBinLOr.
llvm-svn: 60415
2008-12-02 16:02:46 +00:00
Steve Naroff
9af949105a
More work to rewrite synthesize properties (<rdar://problem/6213955>)
...
llvm-svn: 60414
2008-12-02 15:48:25 +00:00
Sebastian Redl
351bb78a10
Handle new by passing the Declaration to the Action, not a processed type.
...
llvm-svn: 60413
2008-12-02 14:43:59 +00:00
Ted Kremenek
817737a002
Add FIXME.
...
llvm-svn: 60390
2008-12-02 01:26:07 +00:00
Eli Friedman
f5d08c9ee4
Disabling this code due to regression on test/CodeGen/bitfield.c. See
...
PR3152.
llvm-svn: 60389
2008-12-02 01:17:45 +00:00
Douglas Gregor
f558618fa4
A little more scaffolding for parsing templates:
...
- Template parameter scope to hold the template parameters
- Template parameter context for parsing declarators
- Actions for template type parameters and non-type template
parameters
llvm-svn: 60387
2008-12-02 00:41:28 +00:00
Fariborz Jahanian
015a48d1db
This patch corrects problem in searching for a setter/getter method for
...
a property. Previous scheme of seaching in interface's list of methods
would not work because this list is not yet constructed. This is in preparation
for doing semantic check on viability of setter/getter method declarations.
llvm-svn: 60386
2008-12-02 00:19:12 +00:00
Douglas Gregor
eb31f39558
Basic support for parsing templates, from Andrew Sutton
...
llvm-svn: 60384
2008-12-01 23:54:00 +00:00
Douglas Gregor
da747baa3c
Improve error recovery when parsing a function definition fails
...
llvm-svn: 60380
2008-12-01 23:03:32 +00:00
Douglas Gregor
b690cbb928
Initialize storage class even if we got an erroneous mutable
...
llvm-svn: 60377
2008-12-01 22:46:22 +00:00
Douglas Gregor
90abb6dead
Objective-C keywords are not always identifiers. Some are also C++ keywords
...
llvm-svn: 60373
2008-12-01 21:46:47 +00:00
Douglas Gregor
dce30aa0f9
Fix RUN line
...
llvm-svn: 60372
2008-12-01 21:17:52 +00:00
Steve Naroff
e1908e393e
-Add several ObjC types to Decl::getDeclKindName(), a useful debug hook.
...
-Start adding support for rewriting @synthesize.
llvm-svn: 60368
2008-12-01 20:33:01 +00:00
Douglas Gregor
e912266bdb
Test blocks in C++ mode
...
llvm-svn: 60367
2008-12-01 19:48:06 +00:00
Douglas Gregor
95c326d14a
Use EmitInt, not Emit, to emit unsigned values
...
llvm-svn: 60364
2008-12-01 19:45:16 +00:00
Daniel Dunbar
0132cdc45c
Add test case for __ASSEMBLER__ definition.
...
llvm-svn: 60363
2008-12-01 19:23:47 +00:00
Daniel Dunbar
1f3d7849a8
Add LangOptions marker for assembler-with-cpp mode and use to define
...
__ASSEMBLER__ properly. Patch from Roman Divacky (with minor
formatting changes). Thanks!
llvm-svn: 60362
2008-12-01 18:55:22 +00:00
Douglas Gregor
c12ce19595
Enable blocks in C++
...
llvm-svn: 60361
2008-12-01 18:34:47 +00:00
Douglas Gregor
2dc61144cd
Make sure __null test runs in both 32- and 64-bit. Thanks Anders
...
llvm-svn: 60360
2008-12-01 18:05:11 +00:00
Douglas Gregor
356513d7d0
Parse the exception-specification throw(...), a Microsoft extension
...
llvm-svn: 60359
2008-12-01 18:00:20 +00:00
Douglas Gregor
dc37c81448
Add the test for __null
...
llvm-svn: 60357
2008-12-01 17:31:21 +00:00
Douglas Gregor
f7ab50df29
Define NULL to __null in C++, so that it's guaranteed to have the same size as a pointer
...
llvm-svn: 60355
2008-12-01 17:20:57 +00:00
Anders Carlsson
5b3638b6e7
Generate the correct results for the comma expression. Fixes PR3123.
...
llvm-svn: 60334
2008-12-01 06:44:05 +00:00
Anders Carlsson
eade3ad1f1
Revert change that made isNullPointerConstant start emitting warnings. We don't want that :)
...
llvm-svn: 60333
2008-12-01 06:28:23 +00:00
Anders Carlsson
0309d904f7
Fix test. (0 && (a(),1)) is a valid I-C-E according to C99.
...
llvm-svn: 60331
2008-12-01 06:27:38 +00:00
Anders Carlsson
8628645e94
Change more code over to using the new Expr::Evaluate
...
llvm-svn: 60324
2008-12-01 02:46:24 +00:00
Anders Carlsson
38eef1de6c
Change more code over to using the new Expr::Evaluate
...
llvm-svn: 60323
2008-12-01 02:42:14 +00:00