File: structsize.c

package info (click to toggle)
euslisp 9.27%2Bdfsg-7
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, bullseye
  • size: 55,344 kB
  • sloc: ansic: 41,162; lisp: 3,339; makefile: 256; sh: 208; asm: 138; python: 53
file content (12 lines) | stat: -rw-r--r-- 184 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
struct {
  short s;
  long  l;} a;

main()
{ int s;
  s=sizeof(a);
  printf("sizeof(struct short + long)= %d\n",s);
  if (s==6) printf("type Sun3\n");
  else printf("type Sun4\n");}