summaryrefslogtreecommitdiffstats
path: root/elaborate.cxx
diff options
context:
space:
mode:
authorfche <fche>2006-02-14 22:12:07 +0000
committerfche <fche>2006-02-14 22:12:07 +0000
commit2a99f48ff1f873f537784d6f70d7641ada1ed7bd (patch)
tree6eb328cf1ad642ecf4ef223f1ea379fd9810e5d5 /elaborate.cxx
parentb9bf008d3a624fa7b470a7d852d970ca27370b90 (diff)
downloadsystemtap-steved-2a99f48ff1f873f537784d6f70d7641ada1ed7bd.tar.gz
systemtap-steved-2a99f48ff1f873f537784d6f70d7641ada1ed7bd.tar.xz
systemtap-steved-2a99f48ff1f873f537784d6f70d7641ada1ed7bd.zip
2006-02-14 Frank Ch. Eigler <fche@elastic.org>
* stapfuncs.5.in: Document new queue_stats tapset. * elaborate.cxx (*): Put "while:" clarification messages before a thrown semantic error. * staptree.cxx (print_format::string_to_components): Correct parse of "%%" formatting element. * queue_stats.stp: New tapset. * systemtap.samples/queue_demo.*: New test.
Diffstat (limited to 'elaborate.cxx')
-rw-r--r--elaborate.cxx17
1 files changed, 12 insertions, 5 deletions
diff --git a/elaborate.cxx b/elaborate.cxx
index ce8844ce..a906bb87 100644
--- a/elaborate.cxx
+++ b/elaborate.cxx
@@ -391,10 +391,10 @@ systemtap_session::register_library_aliases()
}
catch (const semantic_error& e)
{
- print_error (e);
- cerr << " while: registering probe alias ";
+ cerr << "while: registering probe alias ";
alias->printsig(cerr);
cerr << endl;
+ print_error (e);
}
}
}
@@ -442,7 +442,7 @@ derive_probes (systemtap_session& s,
{
// XXX: prefer not to print_error at every nest/unroll level
s.print_error (e);
- cerr << " while: resolving probe point " << *loc << endl;
+ cerr << "while: resolving probe point " << *loc << endl;
// if (! exc_outermost)
// throw;
}
@@ -935,7 +935,11 @@ symresolution_info::visit_foreach_loop (foreach_loop* e)
if (d)
array->referent = d;
else
- throw semantic_error ("unresolved global array " + array->name, e->tok);
+ {
+ cerr << "while searching for arity " << e->indexes.size()
+ << " array:\n";
+ throw semantic_error ("unresolved global array " + array->name, e->tok);
+ }
}
}
else
@@ -1071,7 +1075,10 @@ symresolution_info::visit_functioncall (functioncall* e)
if (d)
e->referent = d;
else
- throw semantic_error ("unresolved function call", e->tok);
+ {
+ cerr << "while searching for arity " << e->args.size() << " function:\n";
+ throw semantic_error ("unresolved function call", e->tok);
+ }
}