|
Last change
on this file since 8b639f9 was 10b5970, checked in by Michael Brooks <mlbrooks@…>, 10 months ago |
|
Fix many test-suite- and libcfa-caused unused variable warnings.
In scope are easy fixes among tests whose sole warnings were unused variable. Reduces the wflags lax list by 40%.
|
-
Property mode
set to
100644
|
|
File size:
368 bytes
|
| Rev | Line | |
|---|
| [97f8f0f] | 1 | // Testing non-polymorphic sizeof (and alignof) expressions:
|
|---|
| 2 |
|
|---|
| 3 | #include <fstream.hfa>
|
|---|
| 4 |
|
|---|
| [10b5970] | 5 | int main() {
|
|---|
| [97f8f0f] | 6 | char val = 'c';
|
|---|
| 7 | char & ref = val;
|
|---|
| 8 | // It could check against "char *", but it should always be different.
|
|---|
| 9 | sout | "char : " | sizeof(val) | alignof(val);
|
|---|
| 10 | sout | "char &: " | sizeof(ref) | alignof(ref);
|
|---|
| [10b5970] | 11 |
|
|---|
| 12 | // FIX ME: work around Trac #300
|
|---|
| 13 | (void) val;
|
|---|
| 14 | (void) ref;
|
|---|
| [97f8f0f] | 15 | }
|
|---|
Note:
See
TracBrowser
for help on using the repository browser.