Overview
Comment: | Evaluates standard CRs (mtt::$cr) after user-defined CRs ($cr). |
---|---|
Downloads: | Tarball | ZIP archive | SQL archive |
Timelines: | family | ancestors | descendants | both | origin/master | trunk |
Files: | files | file ages | folders |
SHA3-256: |
0610867d71d8fc13f1e2d263724e51e9 |
User & Date: | geraint@users.sourceforge.net on 2004-09-03 08:38:28 |
Other Links: | branch diff | manifest | tags |
Context
2004-09-07
| ||
18:22:53 |
Issues a more helpful error message than the cryptic Octave stuff if there are unconnected ports. check-in: b964998861 user: geraint@users.sourceforge.net tags: origin/master, trunk | |
2004-09-03
| ||
08:38:28 | Evaluates standard CRs (mtt::$cr) after user-defined CRs ($cr). check-in: 0610867d71 user: geraint@users.sourceforge.net tags: origin/master, trunk | |
08:36:57 |
Checks for the existence of .pm files in either the working directory or the mtt subdirectory (copied from cr/perl/). check-in: 05c5e3fed7 user: geraint@users.sourceforge.net tags: origin/master, trunk | |
Changes
Modified mttroot/mtt/lib/cr/perl/apply_cr.pl from [1de0fc9f10] to [41a7e19374].
︙ | ︙ | |||
74 75 76 77 78 79 80 | @expressions = (); @prefixes = (); substitute_subexpressions(); display_subexpressions () if ($debug); for ($i = 0; $i <= $#expressions; $i++) { | | < < < < < | 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 | @expressions = (); @prefixes = (); substitute_subexpressions(); display_subexpressions () if ($debug); for ($i = 0; $i <= $#expressions; $i++) { process_expression (); } display_subexpressions () if ($debug); reassemble_expression (); print STDOUT "$expression"; } |
︙ | ︙ | |||
132 133 134 135 136 137 138 | } } } if ($cr eq '') { return; } | | < > | > > > | | > > > > > > > > > > > > > > | 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 | } } } if ($cr eq '') { return; } # call cr(arg1,arg2,...) User-defined CR in the model directory if (-e "$cr.pm") { my $expr = $expressions[$i]; eval "require $cr"; $cr->import (@_[1 .. $#_]); no strict 'refs'; # allow symbolic references my $substitution = &$cr ($expr); use strict 'refs'; if ($substitution) { $prefixes[$i] = ""; $expressions[$i] = "$substitution"; } } # call cr(arg1,arg2,...) Standard CR in the mtt namespace if (-e "mtt/$cr.pm") { my $expr = $expressions[$i]; my $mttcr = "mtt::$cr"; eval "require 'mtt/$cr.pm'"; $mttcr->import (@_[1 .. $#_]); no strict 'refs'; # allow symbolic references my $substitution = &$cr ($expr); use strict 'refs'; if ($substitution) { $prefixes[$i] = ""; $expressions[$i] = "$substitution"; } } } #------------------------------------------------------------------------------- sub display_subexpressions() { for ($i = 0; $i <= $#expressions; $i++) { my $prefix = " "; $prefix = $prefixes[$i] if ($prefixes[$i]); |
︙ | ︙ |