Просмотр исходного кода

[eval] fix breakpoint condition parsing

closes #8230

There is no active frame when parsing breakpoints so we cannot grab a position from there. Might as well use null_pos because it doesn't make a difference.
Simon Krajewski 6 лет назад
Родитель
Сommit
7d6705c5c6
1 измененных файлов с 1 добавлено и 2 удалено
  1. 1 2
      src/macro/eval/evalDebugSocket.ml

+ 1 - 2
src/macro/eval/evalDebugSocket.ml

@@ -509,8 +509,7 @@ let handler =
 		let column = j#get_opt_param (fun () -> BPColumn (j#get_int_field "column" "column" obj)) BPAny in
 		let condition = j#get_opt_param (fun () ->
 			let s = j#get_string_field "condition" "condition" obj in
-			let env = expect_env hctx hctx.ctx.eval.env in (* Use the main env, we only care about the position anyway *)
-			Some (parse_expr hctx.ctx s env.env_debug.expr.epos)
+			Some (parse_expr hctx.ctx s null_pos)
 		) None in
 		(line,column,condition)
 	in