URL
https://opencores.org/ocsvn/openrisc/openrisc/trunk
Only display areas with differences |
Details |
Blame |
View Log
Rev 738 |
Rev 783 |
#include <stdio.h>
|
#include <stdio.h>
|
#include <stdlib.h>
|
#include <stdlib.h>
|
#include <string.h>
|
#include <string.h>
|
int main ()
|
int main ()
|
{
|
{
|
struct foo {int base; char variable[1]; }; /* a common idiom for variable-size structs */
|
struct foo {int base; char variable[1]; }; /* a common idiom for variable-size structs */
|
|
|
struct foo * b = (struct foo *) malloc (sizeof (int)); /* enough for base */
|
struct foo * b = (struct foo *) malloc (sizeof (int)); /* enough for base */
|
b->base = 4;
|
b->base = 4;
|
return 0;
|
return 0;
|
}
|
}
|
|
|
© copyright 1999-2024
OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.