]> granicus.if.org Git - clang/commit
Although we currently have explicit lvalue-to-rvalue conversions, they're
authorJohn McCall <rjmccall@apple.com>
Sat, 4 Dec 2010 03:47:34 +0000 (03:47 +0000)
committerJohn McCall <rjmccall@apple.com>
Sat, 4 Dec 2010 03:47:34 +0000 (03:47 +0000)
commitf6a1648197562e0b133440d612d9af297d0a86cc
tree10c1ff179182b53e5f8eb356b7fe1ace0c7dab41
parente68b9842d2d6adc2c72c81c845a2c68e58d9d3a4
Although we currently have explicit lvalue-to-rvalue conversions, they're
not actually frequently used, because ImpCastExprToType only creates a node
if the types differ.  So explicitly create an ICE in the lvalue-to-rvalue
conversion code in DefaultFunctionArrayLvalueConversion() as well as several
other new places, and consistently deal with the consequences throughout the
compiler.

In addition, introduce a new cast kind for loading an ObjCProperty l-value,
and make sure we emit those nodes whenever an ObjCProperty l-value appears
that's not on the LHS of an assignment operator.

This breaks a couple of rewriter tests, which I've x-failed until future
development occurs on the rewriter.

Ted Kremenek kindly contributed the analyzer workarounds in this patch.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@120890 91177308-0d34-0410-b5e6-96231b3b80d8
30 files changed:
include/clang/AST/Expr.h
include/clang/AST/OperationKinds.h
include/clang/Sema/Sema.h
lib/AST/Expr.cpp
lib/AST/ExprClassification.cpp
lib/Analysis/CFG.cpp
lib/Checker/CheckSecuritySyntaxOnly.cpp
lib/Checker/DereferenceChecker.cpp
lib/Checker/Environment.cpp
lib/Checker/GRExprEngine.cpp
lib/Checker/IdempotentOperationChecker.cpp
lib/CodeGen/CGExpr.cpp
lib/CodeGen/CGExprAgg.cpp
lib/CodeGen/CGExprComplex.cpp
lib/CodeGen/CGExprScalar.cpp
lib/Parse/ParseStmt.cpp
lib/Sema/SemaCXXCast.cpp
lib/Sema/SemaChecking.cpp
lib/Sema/SemaExpr.cpp
lib/Sema/SemaExprCXX.cpp
lib/Sema/SemaExprObjC.cpp
lib/Sema/SemaInit.cpp
lib/Sema/SemaStmt.cpp
test/CodeGen/volatile-1.c
test/CodeGenObjCXX/property-dot-reference.mm
test/Rewriter/properties.m
test/Rewriter/rewrite-nested-property-in-blocks.mm
test/Sema/rdr6094103-unordered-compare-promote.c
test/SemaCXX/decl-expr-ambiguity.cpp
test/SemaTemplate/enum-argument.cpp