Commit 08cdc89a by Eric Christopher

inline-16.c: Use __SIZE_TYPE__.

2006-11-23  Eric Christopher  <echristo@apple.com>

        * gcc.dg/inline-16.c: Use __SIZE_TYPE__.

From-SVN: r119144
parent 422c3a54
2006-11-23 Eric Christopher <echristo@apple.com>
* gcc.dg/inline-16.c: Use __SIZE_TYPE__.
2006-11-24 Manuel Lopez-Ibanez <manu@gcc.gnu.org>
PR c/2707
/* { dg-do link } */
/* { dg-options "-std=c99" } */
static inline int
func1(const volatile void * base, int byteOffset)
static inline __SIZE_TYPE__
func1(const volatile void * base, __SIZE_TYPE__ byteOffset)
{
volatile int *addr = (volatile int *)((int)base + byteOffset);
volatile __SIZE_TYPE__ *addr
= (volatile __SIZE_TYPE__ *)((__SIZE_TYPE__)base + byteOffset);
return *addr;
}
static inline int
func2(int data)
static inline __SIZE_TYPE__
func2(__SIZE_TYPE__ data)
{
return func1(&data, 0);
}
int main(int argc, char *argv[]) {
int b = func2(argc);
__SIZE_TYPE__ b = func2(argc);
return 0;
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment