diff options
author | Josh Stone <jistone@redhat.com> | 2010-02-25 16:20:50 -0800 |
---|---|---|
committer | Josh Stone <jistone@redhat.com> | 2010-02-25 16:20:50 -0800 |
commit | b7aedf26f105793793c66c39c85abe76e1510e66 (patch) | |
tree | e38acbbc143220e87a2226b55832264d970fc144 /tapsets.cxx | |
parent | 70208613b8f9f2584aee89197705f3fddae6a0e4 (diff) | |
download | systemtap-steved-b7aedf26f105793793c66c39c85abe76e1510e66.tar.gz systemtap-steved-b7aedf26f105793793c66c39c85abe76e1510e66.tar.xz systemtap-steved-b7aedf26f105793793c66c39c85abe76e1510e66.zip |
Expand @defined to support more cases
* tapsets.cxx (var_expanding_visitor::visit_defined_op): If no error was
raised or replacement made on a target_symbol, then its @defined state
is still indeterminate. Some later pass (like @cast) might handle it.
* elaborate.cxx (const_folder::visit_defined_op): Squash any escapees.
* testsuite/semok/thirtysix.stp: Add more variants.
Diffstat (limited to 'tapsets.cxx')
-rw-r--r-- | tapsets.cxx | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/tapsets.cxx b/tapsets.cxx index ca439ede..d470b043 100644 --- a/tapsets.cxx +++ b/tapsets.cxx @@ -1982,7 +1982,12 @@ var_expanding_visitor::visit_defined_op (defined_op* e) else if (foo2 && foo2->probe_context_var != "") // successful resolved = true; else if (foo2) // unresolved but not marked either way - assert (0); // should not happen + { + // it might be resolved by some other pass + e->operand = foo2; + provide (e); + return; + } else // resolved, rewritten to some other expression type resolved = true; } catch (const semantic_error& e) { |