OpenCores
URL https://opencores.org/ocsvn/openrisc_2011-10-31/openrisc_2011-10-31/trunk

Subversion Repositories openrisc_2011-10-31

[/] [openrisc/] [trunk/] [gnu-src/] [gcc-4.2.2/] [gcc/] [testsuite/] [gcc.dg/] [cpp/] [if-unary.c] - Blame information for rev 154

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 149 jeremybenn
/* Copyright (C) 2000 Free Software Foundation, Inc.  */
2
 
3
/* { dg-do preprocess } */
4
 
5
/* Test the various unary operators.  */
6
 
7
#if 1 + + + 1   /* allow multiple unary sign operators :) */
8
#endif
9
 
10
#if 8 - +3 != +4 + +1
11
#error          /* { dg-bogus "error" "unary +" } */
12
#endif
13
 
14
#if -2 - -1 != -1
15
#error          /* { dg-bogus "error" "unary -" } */
16
#endif
17
 
18
#if ~0 != -1
19
#error          /* { dg-bogus "error" "unary ~" } */
20
#endif
21
 
22
#if !0 && (!1 == 0) && !!1 != 1
23
#error          /* { dg-bogus "error" "unary !" } */
24
#endif
25
 
26
#if ~~8 != 8
27
#error          /* { dg-bogus "error" "double unary ~" } */
28
#endif
29
 
30
#if 5 + +!-4 != 5
31
#error          /* { dg-bogus "error" "compound unary +, !, -" } */
32
#endif

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.