diff options
-rw-r--r-- | ChangeLog | 6 | ||||
-rw-r--r-- | parse.cxx | 4 | ||||
-rw-r--r-- | testsuite/ChangeLog | 5 | ||||
-rwxr-xr-x | testsuite/parseko/twentysix.stp | 4 |
4 files changed, 19 insertions, 0 deletions
@@ -1,5 +1,11 @@ 2008-11-28 Frank Ch. Eigler <fche@elastic.org> + PR 5376. + * parse.cxx (parse::parse_probe): Prevent alias names from + being marked "?" or "!". + +2008-11-28 Frank Ch. Eigler <fche@elastic.org> + PR 6477. * elaborate.cxx (print_error_source, print_warning): Tolerate NULL token. @@ -1073,6 +1073,8 @@ parser::parse_probe (std::vector<probe *> & probe_ret, if (equals_ok && t && t->type == tok_operator && t->content == "=") { + if (pp->optional || pp->sufficient) + throw parse_error ("probe point alias name cannot be optional nor sufficient", pp->tok); aliases.push_back(pp); next (); continue; @@ -1080,6 +1082,8 @@ parser::parse_probe (std::vector<probe *> & probe_ret, else if (equals_ok && t && t->type == tok_operator && t->content == "+=") { + if (pp->optional || pp->sufficient) + throw parse_error ("probe point alias name cannot be optional nor sufficient", pp->tok); aliases.push_back(pp); epilogue_alias = 1; next (); diff --git a/testsuite/ChangeLog b/testsuite/ChangeLog index df7a24f9..d6fc7686 100644 --- a/testsuite/ChangeLog +++ b/testsuite/ChangeLog @@ -1,3 +1,8 @@ +2008-11-28 Frank Ch. Eigler <fche@elastic.org> + + PR5376. + * parseko/twentysix: New test. + 2008-11-26 Stan Cox <scox@redhat.com> * systemtap.base/static_uprobes.exp: Check debuginfo static uprobes. diff --git a/testsuite/parseko/twentysix.stp b/testsuite/parseko/twentysix.stp new file mode 100755 index 00000000..6f823f90 --- /dev/null +++ b/testsuite/parseko/twentysix.stp @@ -0,0 +1,4 @@ +#! stap -p1 + +# PR 5376 case 3 +probe foo ? = begin { } |