aboutsummaryrefslogtreecommitdiff
path: root/lib/Frontend/RewriteObjC.cpp
AgeCommit message (Collapse)Author
2010-01-20Use the llvm coding convention for indentation for switch.Mike Stump
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@93966 91177308-0d34-0410-b5e6-96231b3b80d8
2010-01-19The type of a compound literal expression is not necessarily the same as theJohn McCall
type which was syntactically written. Fixes PR 6080. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@93933 91177308-0d34-0410-b5e6-96231b3b80d8
2010-01-19Rewriteing of gnu extension __typeof in objective-c rewriter.Fariborz Jahanian
Fixes radar 6358225. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@93917 91177308-0d34-0410-b5e6-96231b3b80d8
2010-01-18Preserve type source information in compound literal expressions.John McCall
Patch by Enea Zaffanella! git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@93752 91177308-0d34-0410-b5e6-96231b3b80d8
2010-01-16Fix a rewriting crash and correct rewriting of __blockFariborz Jahanian
declaration where its initializer has a type-cast. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@93650 91177308-0d34-0410-b5e6-96231b3b80d8
2010-01-15define __weak to null in rewritten source for Fariborz Jahanian
-fms-extensions as well. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@93569 91177308-0d34-0410-b5e6-96231b3b80d8
2010-01-15Preserve type source information in explicit cast expressions.John McCall
Patch by Enea Zaffanella. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@93522 91177308-0d34-0410-b5e6-96231b3b80d8
2010-01-15Do not do the block-specific rewrite when there is no block literals.Fariborz Jahanian
Fixes radar 7546096. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@93519 91177308-0d34-0410-b5e6-96231b3b80d8
2010-01-14Patch to avoid duplicate declaration of byref structsFariborz Jahanian
for __block variables of same name declared in multiple scopes. Fixes radar 7540194 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@93474 91177308-0d34-0410-b5e6-96231b3b80d8
2010-01-14Fix a bug in rewrite whereby functions using blocks put extern "C" in wrong ↵Fariborz Jahanian
place. Fixes radar 7284618. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@93382 91177308-0d34-0410-b5e6-96231b3b80d8
2010-01-12Improve on objective-c pointer recognitionFariborz Jahanian
during rewrite. No functionality chang. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@93241 91177308-0d34-0410-b5e6-96231b3b80d8
2010-01-12Fix rewriting of MacOS sjlj based eh.Fariborz Jahanian
Fixes radar 7522880. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@93219 91177308-0d34-0410-b5e6-96231b3b80d8
2010-01-11Fix rewriting for forward class declaration.Fariborz Jahanian
(fixes radar 6969189). git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@93201 91177308-0d34-0410-b5e6-96231b3b80d8
2010-01-11Fixup rewrite of ivars accessed via an explicit objectFariborz Jahanian
in a function. Fixes radar 7522803. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@93159 91177308-0d34-0410-b5e6-96231b3b80d8
2010-01-10Silence MSVC warning.Benjamin Kramer
RewriteObjC.cpp(4419) : warning C4804: '>' : unsafe use of type 'bool' in operation git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@93124 91177308-0d34-0410-b5e6-96231b3b80d8
2010-01-09revert 91891, a workaround for PR5514.Chris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@93077 91177308-0d34-0410-b5e6-96231b3b80d8
2010-01-08clang ObjC rewriter: generated code used in "for (x in y)" loop uses Fariborz Jahanian
incorrect cast, causing compile error (fixes radar 7342867). git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@92986 91177308-0d34-0410-b5e6-96231b3b80d8
2010-01-07Fixes a bug where we were rewriting two definitions ofFariborz Jahanian
_objc_method (part of radar 7490408). git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@92957 91177308-0d34-0410-b5e6-96231b3b80d8
2010-01-07Fixes a bug in my last patch (related to radar 7490331).Fariborz Jahanian
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@92952 91177308-0d34-0410-b5e6-96231b3b80d8
2010-01-07Avoid error when convering a pointer to integer in Fariborz Jahanian
rewriting. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@92925 91177308-0d34-0410-b5e6-96231b3b80d8
2010-01-07Fix rewriting of ivars. Fixes radar 7490331.Fariborz Jahanian
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@92924 91177308-0d34-0410-b5e6-96231b3b80d8
2010-01-07Fix typo: rename Rewriter::getRewritenText() -> Rewriter::getRewrittenText().Ted Kremenek
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@92922 91177308-0d34-0410-b5e6-96231b3b80d8
2010-01-07Change ObjCContainerDecl to contain the entire range for the '@end'Ted Kremenek
piece of the declaration. The '@' and the 'end' are separate tokens, and require two SourceLocations to accurately track. This change was motivated because ObjCContainerDecl::getSourceRange() would previously not return the entire range of the declaration (the 'end' would be left off). git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@92891 91177308-0d34-0410-b5e6-96231b3b80d8
2010-01-05Fixed a bug where initializer is a macro in rewrite.Fariborz Jahanian
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@92801 91177308-0d34-0410-b5e6-96231b3b80d8
2010-01-05API support for __block variables which are also __weak.Fariborz Jahanian
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@92755 91177308-0d34-0410-b5e6-96231b3b80d8
2010-01-05Minor clean up.Fariborz Jahanian
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@92746 91177308-0d34-0410-b5e6-96231b3b80d8
2010-01-05Remove bogus "C" from preamble block decls.Steve Naroff
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@92744 91177308-0d34-0410-b5e6-96231b3b80d8
2010-01-05More rewriting of __block APIs. wip.Fariborz Jahanian
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@92742 91177308-0d34-0410-b5e6-96231b3b80d8
2010-01-05More rewriting of __block objective-c pointer variables. wip.Fariborz Jahanian
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@92558 91177308-0d34-0410-b5e6-96231b3b80d8
2010-01-04More rewriting of __block declared objective-c/block pointers.Fariborz Jahanian
This is wip. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@92501 91177308-0d34-0410-b5e6-96231b3b80d8
2009-12-30When rewriting a __block declaration, use a suitable API to get location ofFariborz Jahanian
the declaration in the presence of an initializer macro. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@92312 91177308-0d34-0410-b5e6-96231b3b80d8
2009-12-23More cleanup/refactoring of the rewrite.Fariborz Jahanian
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@92062 91177308-0d34-0410-b5e6-96231b3b80d8
2009-12-23Some cleanup and refactoring of rewriter.Fariborz Jahanian
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@92049 91177308-0d34-0410-b5e6-96231b3b80d8
2009-12-23This patch concludes rewriteing of __block variables to allowFariborz Jahanian
a small test case using Block_copy(...) API to pass. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@92038 91177308-0d34-0410-b5e6-96231b3b80d8
2009-12-23Removed a FIXME comment.Fariborz Jahanian
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@92028 91177308-0d34-0410-b5e6-96231b3b80d8
2009-12-23More rewriting of __block variables.Fariborz Jahanian
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@92027 91177308-0d34-0410-b5e6-96231b3b80d8
2009-12-23Add support for handling initializers in RewriteObjC::RewriteByRefVar().Steve Naroff
As the FIXME indicates, RewriteByRefVar() won't work for multiple declarators (in general). I've discussed this with Fariborz and he is aware of the limitation. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@92007 91177308-0d34-0410-b5e6-96231b3b80d8
2009-12-23Patch to do more rewrite of __block variables.Fariborz Jahanian
Still WIP. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91977 91177308-0d34-0410-b5e6-96231b3b80d8
2009-12-22Work around PR5514.Anders Carlsson
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91891 91177308-0d34-0410-b5e6-96231b3b80d8
2009-12-22Template code for rewrite of __block variables - wip.Fariborz Jahanian
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91865 91177308-0d34-0410-b5e6-96231b3b80d8
2009-12-21Providing support for rewriting of block copy/dispose ofFariborz Jahanian
imported block variables. WIP. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91856 91177308-0d34-0410-b5e6-96231b3b80d8
2009-12-18Implemented rewriting of invocation of a block ivar.Fariborz Jahanian
(radar 7482224). git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91652 91177308-0d34-0410-b5e6-96231b3b80d8
2009-12-15Implement conditional block invocation rewriteFariborz Jahanian
and some clean up and a block rewriter test. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91435 91177308-0d34-0410-b5e6-96231b3b80d8
2009-12-07DeclaratorInfo -> TypeSourceInfo. Makes an effort to rename associated ↵John McCall
variables, but the results are imperfect. For posterity, I did: cat <<EOF > $cmdfile s/DeclaratorInfo/TypeSourceInfo/g s/DInfo/TInfo/g s/TypeTypeSourceInfo/TypeSourceInfo/g s/SourceTypeSourceInfo/TypeSourceInfo/g EOF find lib -name '*.cpp' -not -path 'lib/Parse/*' -exec sed -i '' -f $cmdfile '{}' \; find lib -name '*.h' -exec sed -i '' -f $cmdfile '{}' \; find include -name '*.h' -not -path 'include/clang/Parse/*' -not -path 'include/clang/Basic/*' -exec sed -i '' -f $cmdfile '{}' \; git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90743 91177308-0d34-0410-b5e6-96231b3b80d8
2009-12-06Integrate the following from the 'objective-rewrite' branch:Steve Naroff
http://llvm.org/viewvc/llvm-project?view=rev&revision=81871 http://llvm.org/viewvc/llvm-project?view=rev&revision=81936 http://llvm.org/viewvc/llvm-project?view=rev&revision=81945 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90718 91177308-0d34-0410-b5e6-96231b3b80d8
2009-12-06Integrate the following from the 'objective-rewrite' branch:Steve Naroff
http://llvm.org/viewvc/llvm-project?view=rev&revision=86026 Note: The 'improved debugging' changes weren't integrated (since they were later reverted, since they didn't improve debugging). git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90693 91177308-0d34-0410-b5e6-96231b3b80d8
2009-12-06Integrate the following from the 'objective-rewrite' branch:Steve Naroff
http://llvm.org/viewvc/llvm-project?view=rev&revision=82174 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90692 91177308-0d34-0410-b5e6-96231b3b80d8
2009-12-06Integrate the following from the 'objective-rewrite' branch:Steve Naroff
http://llvm.org/viewvc/llvm-project?view=rev&revision=72893 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90690 91177308-0d34-0410-b5e6-96231b3b80d8
2009-12-05Don't call back() on an empty vector.Benjamin Kramer
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90678 91177308-0d34-0410-b5e6-96231b3b80d8
2009-12-05Integrate the following from the 'objective-rewrite' branch:Steve Naroff
http://llvm.org/viewvc/llvm-project?view=rev&revision=71225 http://llvm.org/viewvc/llvm-project?view=rev&revision=73207 http://llvm.org/viewvc/llvm-project?view=rev&revision=73414 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90677 91177308-0d34-0410-b5e6-96231b3b80d8