| Index: runtime/vm/service.cc
|
| diff --git a/runtime/vm/service.cc b/runtime/vm/service.cc
|
| index 35be737034cc8e4dad41d78a6a61baa1475a0c90..631a4ec96c50da5bf7d08b7cfbaf82452cc168be 100644
|
| --- a/runtime/vm/service.cc
|
| +++ b/runtime/vm/service.cc
|
| @@ -2332,6 +2332,7 @@ static const MethodParameter* get_source_report_params[] = {
|
| new IdParameter("scriptId", false),
|
| new UIntParameter("tokenPos", false),
|
| new UIntParameter("endTokenPos", false),
|
| + new BoolParameter("forceCompile", false),
|
| NULL,
|
| };
|
|
|
| @@ -2349,6 +2350,11 @@ static bool GetSourceReport(Thread* thread, JSONStream* js) {
|
| reports++;
|
| }
|
|
|
| + SourceReport::CompileMode compile_mode = SourceReport::kNoCompile;
|
| + if (BoolParameter::Parse(js->LookupParam("forceCompile"), false)) {
|
| + compile_mode = SourceReport::kForceCompile;
|
| + }
|
| +
|
| Script& script = Script::Handle();
|
| intptr_t start_pos = UIntParameter::Parse(js->LookupParam("tokenPos"));
|
| intptr_t end_pos = UIntParameter::Parse(js->LookupParam("endTokenPos"));
|
| @@ -2379,7 +2385,7 @@ static bool GetSourceReport(Thread* thread, JSONStream* js) {
|
| return true;
|
| }
|
| }
|
| - SourceReport report(report_set);
|
| + SourceReport report(report_set, compile_mode);
|
| report.PrintJSON(js, script, start_pos, end_pos);
|
| return true;
|
| }
|
|
|