diff options
author | Fariborz Jahanian <fjahanian@apple.com> | 2012-03-05 19:34:00 +0000 |
---|---|---|
committer | Fariborz Jahanian <fjahanian@apple.com> | 2012-03-05 19:34:00 +0000 |
commit | abf9d908cce6ffe2ee7b739d98fc7344a4f9fe3b (patch) | |
tree | 78ff3c89d85ee81fc80ef1962d1c9add5b2e6b6a /include/clang/Basic | |
parent | a187c5cc7cbc4931ef488374648348de5c057aee (diff) |
patch to optionally warn for block implementations without explicit
return types that return non-void values. // rdar://10735698
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@152047 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/clang/Basic')
-rw-r--r-- | include/clang/Basic/DiagnosticSemaKinds.td | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/include/clang/Basic/DiagnosticSemaKinds.td b/include/clang/Basic/DiagnosticSemaKinds.td index 5d3ff2a4af..816956051c 100644 --- a/include/clang/Basic/DiagnosticSemaKinds.td +++ b/include/clang/Basic/DiagnosticSemaKinds.td @@ -4953,6 +4953,10 @@ def err_blocks_disable : Error<"blocks support disabled - compile with -fblocks" " or pick a deployment target that supports them">; def err_block_returning_array_function : Error< "block cannot return %select{array|function}0 type %1">; +def warn_block_missing_return_type : Warning< + "block literal is missing explicit return type and " + "returns non-void values">, + InGroup<DiagGroup<"block-missing-explicit-return-type">>, DefaultIgnore; // Builtin annotation string. def err_builtin_annotation_not_string_constant : Error< |