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

Subversion Repositories scarts

[/] [scarts/] [trunk/] [toolchain/] [scarts-gcc/] [gcc-4.1.1/] [gcc/] [testsuite/] [gcc.dg/] [Wint-to-pointer-cast-3.c] - Blame information for rev 12

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 12 jlechner
/* Test -Wno-int-to-pointer-cast.  */
2
/* Origin: Joseph Myers <joseph@codesourcery.com> */
3
/* { dg-do compile } */
4
/* { dg-options "-Wno-int-to-pointer-cast" } */
5
 
6
char c;
7
 
8
void *
9
f (void)
10
{
11
  return (void *) c;
12
}
13
 
14
void *p;
15
 
16
char
17
g (void)
18
{
19
  return (char) p; /* { dg-warning "warning: cast from pointer to integer of different size" } */
20
}

powered by: WebSVN 2.1.0

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