summaryrefslogtreecommitdiffstats
path: root/parse.cxx
diff options
context:
space:
mode:
authorFrank Ch. Eigler <fche@elastic.org>2008-11-28 12:06:27 -0500
committerFrank Ch. Eigler <fche@elastic.org>2008-11-28 12:06:27 -0500
commit1ad820e32419c6ff9237962ec911e9c4eee79c4a (patch)
treef30826abe997f75ac590c03c88718d3b89ec1a45 /parse.cxx
parent29bdbdb17f088a997b772415d57c37258576f0f5 (diff)
downloadsystemtap-steved-1ad820e32419c6ff9237962ec911e9c4eee79c4a.tar.gz
systemtap-steved-1ad820e32419c6ff9237962ec911e9c4eee79c4a.tar.xz
systemtap-steved-1ad820e32419c6ff9237962ec911e9c4eee79c4a.zip
PR5376: probe alias parsing tweaks
Diffstat (limited to 'parse.cxx')
-rw-r--r--parse.cxx4
1 files changed, 4 insertions, 0 deletions
diff --git a/parse.cxx b/parse.cxx
index 1982eb44..7f1e5d2a 100644
--- a/parse.cxx
+++ b/parse.cxx
@@ -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 ();