diff options
author | Ian Romanick <ian.d.romanick@intel.com> | 2010-03-23 12:28:44 -0700 |
---|---|---|
committer | Ian Romanick <ian.d.romanick@intel.com> | 2010-03-23 12:28:44 -0700 |
commit | cec65a6b76290ee4da91691bd3ef01c3fb8a0c37 (patch) | |
tree | ef60de3deccbe70ea79a157e34c10c17fed5e080 | |
parent | 8400bc4d35fe7aa0ce605e4f4bb837227dfcacf9 (diff) |
Generate an error for variables declared with type void
-rw-r--r-- | ast_to_hir.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/ast_to_hir.cpp b/ast_to_hir.cpp index feeb0d925d..62f2068b3a 100644 --- a/ast_to_hir.cpp +++ b/ast_to_hir.cpp @@ -841,7 +841,7 @@ ast_declarator_list::hir(exec_list *instructions, * FINISHME: declaration at a higher scope. */ - if (decl_type == NULL) { + if ((decl_type == NULL) || decl_type->is_void()) { YYLTYPE loc; loc = this->get_location(); |