summaryrefslogtreecommitdiff
path: root/parse.y
diff options
context:
space:
mode:
Diffstat (limited to 'parse.y')
-rw-r--r--parse.y13
1 files changed, 13 insertions, 0 deletions
diff --git a/parse.y b/parse.y
index a025a51db7..5741eb9ff6 100644
--- a/parse.y
+++ b/parse.y
@@ -29,6 +29,7 @@
#include <stdio.h>
#include <errno.h>
#include <ctype.h>
+#include "probes.h"
#define numberof(array) (int)(sizeof(array) / sizeof((array)[0]))
@@ -5310,7 +5311,19 @@ yycompile0(VALUE arg)
#ifndef RIPPER
parser->parser_token_info_enabled = !compile_for_eval && RTEST(ruby_verbose);
#endif
+#ifndef RIPPER
+ if(RUBY_DTRACE_PARSE_BEGIN_ENABLED()) {
+ RUBY_DTRACE_PARSE_BEGIN(parser->parser_ruby_sourcefile,
+ parser->parser_ruby_sourceline);
+ }
+#endif
n = yyparse((void*)parser);
+#ifndef RIPPER
+ if(RUBY_DTRACE_PARSE_END_ENABLED()) {
+ RUBY_DTRACE_PARSE_END(parser->parser_ruby_sourcefile,
+ parser->parser_ruby_sourceline);
+ }
+#endif
ruby_debug_lines = 0;
ruby_coverage = 0;
compile_for_eval = 0;