Parser: Removing debug code.
authormarja <marja@chromium.org>
Tue, 2 Dec 2014 10:31:40 +0000 (02:31 -0800)
committerCommit bot <commit-bot@chromium.org>
Tue, 2 Dec 2014 10:31:54 +0000 (10:31 +0000)
The mystery crash never reappeared once the debugging code was in place.

R=jochen@chromium.org
BUG=

Review URL: https://codereview.chromium.org/760863003

Cr-Commit-Position: refs/heads/master@{#25601}

src/parser.cc
src/parser.h

index 22c0f5c..83fb594 100644 (file)
@@ -835,7 +835,6 @@ FunctionLiteral* Parser::ParseProgram() {
   // Initialize parser state.
   CompleteParserRecorder recorder;
 
-  debug_saved_compile_options_ = compile_options();
   if (produce_cached_parse_data()) {
     log_ = &recorder;
   } else if (consume_cached_parse_data()) {
@@ -3828,13 +3827,6 @@ void Parser::SkipLazyFunctionBody(const AstRawString* function_name,
                                   int* materialized_literal_count,
                                   int* expected_property_count,
                                   bool* ok) {
-  // Temporary debugging code for tracking down a mystery crash which should
-  // never happen. The crash happens on the line where we log the function in
-  // the preparse data: log_->LogFunction(...). TODO(marja): remove this once
-  // done.
-  CHECK(materialized_literal_count);
-  CHECK(expected_property_count);
-  CHECK(debug_saved_compile_options_ == compile_options());
   if (produce_cached_parse_data()) CHECK(log_);
 
   int function_block_pos = position();
@@ -5148,7 +5140,6 @@ void Parser::ParseOnBackground() {
   fni_ = new (zone()) FuncNameInferrer(ast_value_factory(), zone());
 
   CompleteParserRecorder recorder;
-  debug_saved_compile_options_ = compile_options();
   if (produce_cached_parse_data()) log_ = &recorder;
 
   DCHECK(info()->source_stream() != NULL);
index 23acab6..4d60272 100644 (file)
@@ -907,10 +907,6 @@ class Parser : public ParserBase<ParserTraits> {
   int use_counts_[v8::Isolate::kUseCounterFeatureCount];
   int total_preparse_skipped_;
   HistogramTimer* pre_parse_timer_;
-
-  // Temporary; for debugging. See Parser::SkipLazyFunctionBody. TODO(marja):
-  // remove this once done.
-  ScriptCompiler::CompileOptions debug_saved_compile_options_;
 };