summaryrefslogtreecommitdiffstats
path: root/clang/test/Sema/alias-redefinition.c
Commit message (Collapse)AuthorAgeFilesLines
* Process attributes 'ifunc' and 'alias' when checking for redefinitionSerge Pavlov2017-02-181-2/+1
| | | | | | | | | | These attributes effectively turn a non-defining declaration into a definition, so the case when the declaration already has a body must be diagnosed properly. Differential Revision: https://reviews.llvm.org/D30032 llvm-svn: 295541
* Revert "Sema: err_after_alias is unreachable, remove it"David Majnemer2015-01-211-3/+2
| | | | | | This reverts commit r226626. err_after_alias is, in fact, reachable. llvm-svn: 226633
* Sema: err_after_alias is unreachable, remove itDavid Majnemer2015-01-211-0/+4
| | | | | | | Examples this would have catched are now handled by the attribute verification code. llvm-svn: 226626
* Add back a check removed in r226436David Majnemer2015-01-191-0/+3
| | | | | | | It shouldn't have been removed, the code which replaced it didn't cover this case. llvm-svn: 226442
* Sema: Variable definitions cannot be __attribute__((alias))David Majnemer2015-01-191-19/+2
| | | | | | | | | | | | | | | | | | | | Things that are OK: extern int var1 __attribute((alias("v1"))); static int var2 __attribute((alias("v2"))); Things that are not OK: int var3 __attribute((alias("v3"))); extern int var4 __attribute((alias("v4"))) = 4; We choose to accpet: struct S { static int var5 __attribute((alias("v5"))); }; This code causes assertion failues in GCC 4.8 and ICC 13.0.1, we have no reason to reject it. This partially fixes PR22217. llvm-svn: 226436
* Treat aliases as definitions.Rafael Espindola2013-10-221-0/+44
This fixes pr17639. Before this patch clang would consider void foo(void) __attribute((alias("__foo"))); a declaration. It now correctly handles it as a definition. Initial patch by Alp Toker. I added support for variables. llvm-svn: 193200
OpenPOWER on IntegriCloud