File: initializer.i

package info (click to toggle)
frama-c 20220511-manganese-3
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 66,472 kB
  • sloc: ml: 278,832; ansic: 47,093; sh: 4,823; makefile: 3,618; javascript: 2,436; python: 1,919; perl: 897; lisp: 293; xml: 62
file content (36 lines) | stat: -rw-r--r-- 581 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
const char STRS [2][7] = { {"ABCDEF"}, {"IJKLML"} };

enum bool { INVALID, VALID};

struct signal {
  float val;
  enum bool status;
};

struct signals {
  struct signal f1;
  struct signal f2;
  struct signal f3;
  struct signal f4;
  struct signal f5;
  struct signal f6;
  struct signal f7;
};

const struct signals signals = {
  { 0.0, VALID },
  { 0.0, VALID },
  { 0.0, VALID },
  { 0.0, VALID },
  { 0.0, INVALID },
  { 0.0, VALID },
};

struct signal tsig [3] = { 0.1, INVALID, 3, VALID };


void main() {
  static unsigned char STR [] = { "123456" };

  int i = STR[2];
}