Differences From Artifact [2bb4150078]:

To Artifact [c5c057bec5]:


8
9
10
11
12
13
14



15
16
17
18
19
20
21
# Copyright (c) P.J.Gawthrop, 1996.

###############################################################
## Version control history
###############################################################
## $Id$
## $Log$



## Revision 1.12  1998/07/04 11:09:46  peterg
## Cleaned up - assumes new lbl style for SS
##
## Revision 1.11  1998/05/13 12:39:23  peterg
## Added `unknown' to list od names to avoid
##
## Revision 1.10  1998/03/26 13:03:23  peterg







>
>
>







8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
# Copyright (c) P.J.Gawthrop, 1996.

###############################################################
## Version control history
###############################################################
## $Id$
## $Log$
## Revision 1.13  1998/07/15 09:26:50  peterg
## Reinstated the second column of the sympar file - the system name
##
## Revision 1.12  1998/07/04 11:09:46  peterg
## Cleaned up - assumes new lbl style for SS
##
## Revision 1.11  1998/05/13 12:39:23  peterg
## Added `unknown' to list od names to avoid
##
## Revision 1.10  1998/03/26 13:03:23  peterg
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74

75
76
77
78
79
80
81
82


83
84
85
86
87
88
89
##
###############################################################



function exact_match(name1, name2) {
  return ((match(name1,name2)>0)&&(length(name1)==length(name2)))
    }

function matches(names, name) {
  n_matches = split(names,match_name);
  matched = 0;
  for (i_matches = 1; i_matches <= n_matches; i_matches++) {
    if ( exact_match(name,match_name[i_matches]) ) {
      matched = 1;
      break;
    }
  }
  return matched;
    }


BEGIN {
sys_name = ARGV[1];
comment = "%";

arg_delimiter = ",";
not_an_arg = "effort flow state internal external zero unknown 0 1";
SS_parameter = "internal external zero 0 1";
numeric = "[0-9-]";
symbol_count = 0;
symbols = "";
}
{


  if ( (match($1,comment)==0) && (NF>=3) ) {
    n_args = split($3,arg,arg_delimiter);
    for (i = 1; i <= n_args; i++) {
      first_char = substr(arg[i],1,1);
      if ( (matches(not_an_arg,arg[i])==0) \
	   && (match(first_char,numeric)==0) \
	   && (match(arg[i],"\\$")==0) \







|











|




|
>








>
>







53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
##
###############################################################



function exact_match(name1, name2) {
  return ((match(name1,name2)>0)&&(length(name1)==length(name2)))
}

function matches(names, name) {
  n_matches = split(names,match_name);
  matched = 0;
  for (i_matches = 1; i_matches <= n_matches; i_matches++) {
    if ( exact_match(name,match_name[i_matches]) ) {
      matched = 1;
      break;
    }
  }
  return matched;
}


BEGIN {
sys_name = ARGV[1];
comment = "%|#";
var = "[%|#]VAR";
arg_delimiter = ",";
not_an_arg = "effort flow state internal external zero unknown 0 1";
SS_parameter = "internal external zero 0 1";
numeric = "[0-9-]";
symbol_count = 0;
symbols = "";
}
{
  if (match($1,var)>0) print $2 "\t" name;

  if ( (match($1,comment)==0) && (NF>=3) ) {
    n_args = split($3,arg,arg_delimiter);
    for (i = 1; i <= n_args; i++) {
      first_char = substr(arg[i],1,1);
      if ( (matches(not_an_arg,arg[i])==0) \
	   && (match(first_char,numeric)==0) \
	   && (match(arg[i],"\\$")==0) \

MTT: Model Transformation Tools
GitHub | SourceHut | Sourceforge | Fossil RSS ]