OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [gcc.dg/] [cpp/] [if-unary.c] - Blame information for rev 754

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 689 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.