Martin Kustermann
587e6308bf
[vm] Fix expression evaluation in context of closures
...
When evaluating an expressino at a breakpoint that's inside a closure,
the closure may refer to anything it closes over. That includes the
`this` from an enclosing method.
So depending on whether a closure's parent chain is an instance method
or a static method, the expression evaluation function is going to be an
instance method or a static method.
=> We walk up the parent chain to determine the correct enclosing class.
=> This avoids making a Type object with a cid from a top-level class (see [0])
Handling this correctly will now try to get the `this` when invoking an
eval function that has an enclosing instance method. Though we may often
have "<optimized out>" the `this` (e.g. due to not capturing it in
closure context chain).
=> We still allow running the expression evaluation function in this
case, but only if the expression being evaluated doesn't access `this`.
A similar issue occurs when trying to use variables in the eval
expression that the closure didn't capture. This results in a confusing
CFE compile-time error. This is a separate issue and tracked in [1].
=> We update the test to distinuish the cases that this CL makes passing
and those that are failing due to [1].
Fixes [0] https://github.com/dart-lang/sdk/issues/53061
See also [1] https://github.com/dart-lang/sdk/issues/53087
TEST=Fixes part of service/evaluate_activation_test failures
Change-Id: I3bb24e7338c7b2f12d5340311d944cb59a455641
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/317540
Reviewed-by: Alexander Markov <alexmarkov@google.com >
Reviewed-by: Slava Egorov <vegorov@google.com >
Commit-Queue: Martin Kustermann <kustermann@google.com >
2023-08-04 11:07:46 +00:00
..
2023-08-04 11:07:46 +00:00
2023-07-10 12:23:15 +00:00
2023-07-27 20:17:17 +00:00
2023-04-17 15:58:28 +00:00
2023-06-15 19:01:00 +00:00
2023-08-01 20:34:21 +00:00
2023-04-20 17:42:06 +00:00
2023-06-06 02:07:58 +00:00
2023-04-10 18:15:12 +00:00
2023-05-24 08:42:14 +00:00
2023-07-03 12:29:15 +00:00
2023-07-26 23:23:26 +00:00
2023-06-06 16:20:47 +00:00
2023-03-30 19:27:17 +00:00
2023-04-21 08:06:49 +00:00
2023-04-10 18:15:12 +00:00
2023-04-10 18:15:12 +00:00
2023-04-12 22:18:54 +00:00
2021-03-19 15:29:57 +00:00
2023-07-11 15:13:58 +00:00
2023-04-12 22:18:54 +00:00
2023-03-06 22:06:59 +00:00
2023-03-06 22:06:59 +00:00
2023-05-10 11:38:57 +00:00
2023-06-28 01:00:18 +00:00
2023-04-12 22:18:54 +00:00
2023-04-10 18:15:12 +00:00
2023-06-28 01:00:18 +00:00
2023-06-28 01:00:18 +00:00
2023-06-15 19:01:00 +00:00
2023-02-06 21:49:07 +00:00
2023-07-26 23:23:26 +00:00
2021-03-02 16:28:12 +00:00
2023-07-26 21:14:09 +00:00
2023-06-15 00:34:18 +00:00
2023-06-21 15:24:30 +00:00
2023-04-20 17:42:06 +00:00
2023-07-27 20:17:17 +00:00
2023-06-28 11:48:26 +00:00
2023-06-28 11:48:26 +00:00
2023-04-10 18:15:12 +00:00
2023-04-10 18:15:12 +00:00
2023-04-12 22:18:54 +00:00
2023-04-10 18:15:12 +00:00
2021-09-10 22:21:36 +00:00
2023-04-12 22:18:54 +00:00
2021-09-10 22:21:36 +00:00
2023-04-10 18:15:12 +00:00
2021-09-10 22:21:36 +00:00
2023-04-12 22:18:54 +00:00
2022-01-20 00:57:57 +00:00
2023-04-10 18:15:12 +00:00
2021-09-10 22:21:36 +00:00
2023-04-10 18:15:12 +00:00
2023-01-20 12:37:49 +00:00
2023-04-10 18:15:12 +00:00
2023-04-10 18:15:12 +00:00
2022-02-22 21:48:14 +00:00
2023-06-28 01:00:18 +00:00
2022-02-22 21:48:14 +00:00
2023-06-28 01:00:18 +00:00
2022-06-08 19:41:52 +00:00
2022-06-08 22:57:03 +00:00
2023-06-28 01:00:18 +00:00
2023-08-01 17:01:41 +00:00
2023-07-11 15:13:58 +00:00
2022-06-08 22:57:03 +00:00
2023-06-28 01:00:18 +00:00
2022-06-08 22:57:03 +00:00
2023-06-23 20:35:00 +00:00
2023-02-27 22:26:36 +00:00
2023-06-23 20:35:00 +00:00
2021-12-16 21:33:49 +00:00
2023-06-23 20:35:00 +00:00
2021-12-16 21:33:49 +00:00
2023-06-23 20:35:00 +00:00
2022-01-20 00:57:57 +00:00
2022-01-20 00:57:57 +00:00
2023-06-23 20:35:00 +00:00
2021-12-16 21:33:49 +00:00
2022-01-20 00:57:57 +00:00
2023-04-10 18:15:12 +00:00
2022-11-14 15:42:52 +00:00
2023-05-22 16:43:04 +00:00
2023-04-10 21:38:57 +00:00
2023-04-10 21:38:57 +00:00
2023-04-10 21:38:57 +00:00
2023-07-12 17:14:18 +00:00
2022-01-20 00:57:57 +00:00
2023-04-10 18:15:12 +00:00
2023-07-20 17:06:44 +00:00
2023-07-28 10:01:53 +00:00
2023-04-20 17:42:06 +00:00
2023-07-26 21:53:49 +00:00
2021-10-14 00:10:12 +00:00
2023-07-20 17:06:44 +00:00
2023-06-29 17:29:48 +00:00
2023-07-27 20:17:17 +00:00
2023-07-18 19:33:37 +00:00
2023-06-29 08:04:20 +00:00
2021-04-26 07:52:47 +00:00
2021-07-08 14:22:54 +00:00
2023-04-12 22:18:54 +00:00
2023-04-10 18:15:12 +00:00
2023-04-10 18:15:12 +00:00
2021-03-19 20:24:48 +00:00
2021-03-19 20:24:48 +00:00
2021-03-19 20:24:48 +00:00
2022-01-20 00:57:57 +00:00
2021-03-19 20:24:48 +00:00
2023-08-04 11:07:46 +00:00
2023-06-30 14:03:03 +00:00
2023-04-10 18:15:12 +00:00
2023-04-10 18:15:12 +00:00
2023-07-26 21:53:49 +00:00
2023-04-12 22:18:54 +00:00
2022-09-12 12:33:57 +00:00
2022-09-12 12:33:57 +00:00
2023-04-12 22:18:54 +00:00
2023-04-12 22:18:54 +00:00
2023-04-12 22:18:54 +00:00
2023-07-11 15:13:58 +00:00
2023-05-31 08:06:08 +00:00
2023-06-06 02:07:58 +00:00
2022-10-06 10:33:09 +00:00
2023-04-10 18:15:12 +00:00
2023-06-15 17:19:37 +00:00
2023-06-15 17:19:37 +00:00
2023-07-28 23:56:52 +00:00
2023-07-28 23:56:52 +00:00
2023-07-26 23:23:26 +00:00
2023-07-26 23:23:26 +00:00
2023-06-28 09:21:11 +00:00
2023-04-26 22:18:51 +00:00
2023-07-27 20:17:17 +00:00
2023-04-10 18:15:12 +00:00
2023-04-10 18:15:12 +00:00
2023-08-01 16:11:40 +00:00
2023-04-10 18:15:12 +00:00
2023-04-10 18:15:12 +00:00
2023-03-29 18:11:49 +00:00
2023-07-26 21:53:49 +00:00
2023-04-18 19:39:05 +00:00
2023-02-06 22:19:55 +00:00
2023-04-10 18:15:12 +00:00
2023-06-23 20:35:00 +00:00
2023-06-23 20:35:00 +00:00
2023-04-10 18:15:12 +00:00
2023-04-12 22:18:54 +00:00
2023-04-10 18:15:12 +00:00
2022-01-21 02:02:00 +00:00
2023-06-27 19:42:15 +00:00
2022-12-01 10:15:58 +00:00
2023-06-06 02:07:58 +00:00
2023-05-31 08:06:08 +00:00
2023-07-11 15:13:58 +00:00
2023-04-12 22:18:54 +00:00
2022-05-11 19:52:45 +00:00
2023-04-12 22:18:54 +00:00
2023-04-12 22:18:54 +00:00
2022-01-20 00:57:57 +00:00
2023-04-13 19:29:47 +00:00
2023-04-12 22:18:54 +00:00
2023-03-06 22:06:59 +00:00
2023-04-12 22:18:54 +00:00
2022-05-11 19:52:45 +00:00
2022-05-11 19:52:45 +00:00
2023-07-26 21:14:09 +00:00
2023-08-01 19:36:50 +00:00
2023-05-10 19:08:23 +00:00
2023-04-19 09:36:41 +00:00
2023-08-01 15:50:11 +00:00
2023-07-26 23:23:26 +00:00
2023-06-09 17:57:12 +00:00
2023-06-09 17:57:12 +00:00
2023-04-17 15:58:28 +00:00
2023-04-17 15:58:28 +00:00
2023-04-17 15:58:28 +00:00
2023-07-14 10:15:06 +00:00
2023-08-01 09:04:38 +00:00
2023-07-28 10:01:53 +00:00
2023-07-28 10:01:53 +00:00
2023-08-01 09:04:38 +00:00
2023-07-14 10:15:06 +00:00
2022-11-11 01:59:28 +00:00
2023-07-14 10:15:06 +00:00
2023-07-14 10:15:06 +00:00
2023-04-19 08:47:31 +00:00
2023-04-10 18:15:12 +00:00
2023-04-10 18:15:12 +00:00
2022-05-11 19:31:04 +00:00
2021-09-30 13:19:42 +00:00
2023-04-20 17:42:06 +00:00
2023-04-10 18:15:12 +00:00
2021-09-16 17:18:37 +00:00
2023-06-29 08:04:20 +00:00
2023-06-29 08:04:20 +00:00
2023-04-12 22:18:54 +00:00
2023-04-10 18:15:12 +00:00
2023-04-10 18:15:12 +00:00
2023-04-10 18:15:12 +00:00
2023-04-21 13:56:49 +00:00
2023-06-27 22:23:17 +00:00
2023-07-11 10:15:58 +00:00
2022-08-19 18:10:15 +00:00
2023-04-10 18:15:12 +00:00
2023-04-10 18:15:12 +00:00
2023-07-26 21:53:49 +00:00
2023-03-29 19:58:33 +00:00
2023-04-10 18:15:12 +00:00
2023-03-29 19:58:33 +00:00
2023-04-10 18:15:12 +00:00
2023-04-19 09:36:41 +00:00
2023-07-26 21:53:49 +00:00
2023-04-10 18:15:12 +00:00
2023-04-12 22:18:54 +00:00
2021-09-02 14:14:35 +00:00
2023-04-10 18:15:12 +00:00
2023-04-10 18:15:12 +00:00
2023-04-10 18:15:12 +00:00
2023-04-10 18:15:12 +00:00
2023-04-10 18:15:12 +00:00
2023-04-12 22:18:54 +00:00
2023-07-26 21:53:49 +00:00
2023-02-23 03:11:08 +00:00
2023-04-10 18:15:12 +00:00
2023-05-10 16:12:28 +00:00
2023-04-12 22:18:54 +00:00
2023-04-10 18:15:12 +00:00
2023-04-10 18:15:12 +00:00
2023-04-12 22:18:54 +00:00
2023-07-26 21:14:09 +00:00
2022-01-20 00:57:57 +00:00
2023-08-01 20:34:21 +00:00
2023-06-27 07:18:50 +00:00
2023-06-30 14:03:03 +00:00
2023-07-24 16:55:47 +00:00
2023-08-04 11:07:46 +00:00
2023-08-04 11:07:46 +00:00
2023-06-12 15:26:29 +00:00
2023-06-12 15:26:29 +00:00
2023-06-14 20:36:48 +00:00
2023-06-12 15:26:29 +00:00
2023-04-10 18:15:12 +00:00
2023-04-10 18:15:12 +00:00
2022-03-10 23:48:05 +00:00
2023-04-10 18:15:12 +00:00
2023-04-10 18:15:12 +00:00
2021-03-31 20:51:32 +00:00
2023-04-10 18:15:12 +00:00
2023-04-10 18:15:12 +00:00
2023-04-10 18:15:12 +00:00
2023-07-10 20:33:33 +00:00
2023-07-10 20:33:33 +00:00
2023-06-12 15:26:29 +00:00
2023-06-12 15:26:29 +00:00
2023-06-30 14:03:03 +00:00
2023-08-04 11:07:46 +00:00
2022-06-02 23:39:45 +00:00
2022-06-02 23:39:45 +00:00
2023-05-15 20:51:38 +00:00
2022-09-27 21:34:05 +00:00
2023-04-12 22:18:54 +00:00
2023-08-01 15:50:11 +00:00
2022-08-19 18:10:15 +00:00
2023-04-10 18:15:12 +00:00
2021-07-02 19:06:45 +00:00
2023-05-15 20:51:38 +00:00
2023-05-03 19:17:11 +00:00
2023-04-12 22:18:54 +00:00
2023-04-20 17:42:06 +00:00
2023-04-19 09:36:41 +00:00
2023-04-19 08:47:31 +00:00
2021-08-24 16:49:23 +00:00
2023-04-10 18:15:12 +00:00
2023-08-01 15:50:11 +00:00
2023-07-14 10:15:06 +00:00
2022-12-01 14:38:44 +00:00
2023-04-28 19:29:36 +00:00
2023-07-27 20:17:17 +00:00
2023-04-10 18:15:12 +00:00
2023-04-12 22:18:54 +00:00
2023-04-10 18:15:12 +00:00
2023-04-10 18:15:12 +00:00
2023-04-12 22:18:54 +00:00
2023-04-10 18:15:12 +00:00
2023-04-12 22:18:54 +00:00
2023-04-12 22:18:54 +00:00
2023-04-12 22:18:54 +00:00
2021-09-02 19:22:16 +00:00
2023-07-06 21:10:28 +00:00
2023-04-12 22:18:54 +00:00
2023-04-10 18:15:12 +00:00
2023-04-12 22:18:54 +00:00
2023-04-12 22:18:54 +00:00
2022-12-29 10:18:02 +00:00
2023-04-12 22:18:54 +00:00
2023-04-10 18:15:12 +00:00
2023-04-10 18:15:12 +00:00
2021-12-16 10:39:49 +00:00
2021-12-16 10:39:49 +00:00
2023-04-12 22:18:54 +00:00
2022-03-22 19:45:03 +00:00
2022-03-22 19:45:03 +00:00
2022-03-22 19:45:03 +00:00
2023-06-28 01:00:18 +00:00
2022-03-22 19:45:03 +00:00
2022-03-22 19:45:03 +00:00
2023-07-11 22:31:57 +00:00
2023-06-28 01:00:18 +00:00
2021-05-11 11:15:53 +00:00
2023-04-10 18:15:12 +00:00
2023-08-04 11:07:46 +00:00
2023-08-04 11:07:46 +00:00
2023-06-09 17:57:12 +00:00
2021-07-16 20:50:58 +00:00
2023-06-29 08:04:20 +00:00
2023-04-10 18:15:12 +00:00
2023-04-10 18:15:12 +00:00
2023-08-04 11:07:46 +00:00
2023-08-01 20:34:21 +00:00
2023-06-23 17:01:58 +00:00
2021-08-16 11:11:04 +00:00
2023-06-23 17:01:58 +00:00
2023-01-06 07:48:22 +00:00
2021-08-16 11:11:04 +00:00
2021-08-16 11:11:04 +00:00
2023-07-21 19:06:43 +00:00
2023-07-21 19:06:43 +00:00
2023-07-21 19:06:43 +00:00
2023-07-21 19:06:43 +00:00
2023-07-11 15:13:58 +00:00
2023-04-12 22:18:54 +00:00
2023-07-11 15:13:58 +00:00
2023-04-12 22:18:54 +00:00
2022-07-29 18:11:01 +00:00
2023-04-12 22:18:54 +00:00
2023-04-10 18:15:12 +00:00
2023-04-12 22:18:54 +00:00
2023-07-17 15:01:21 +00:00
2023-07-13 08:17:38 +00:00
2023-04-10 18:15:12 +00:00
2023-04-12 22:18:54 +00:00
2023-04-12 22:18:54 +00:00
2023-04-12 22:18:54 +00:00
2023-04-12 22:18:54 +00:00
2023-04-28 23:25:43 +00:00
2023-04-12 22:18:54 +00:00
2023-04-10 18:15:12 +00:00
2023-04-12 22:18:54 +00:00
2023-06-30 14:03:03 +00:00
2023-06-30 14:03:03 +00:00
2022-03-22 19:45:03 +00:00
2022-03-22 19:45:03 +00:00
2022-03-22 19:45:03 +00:00
2023-07-03 10:39:53 +00:00
2022-03-22 19:45:03 +00:00
2022-03-22 19:45:03 +00:00
2023-06-06 02:07:58 +00:00
2023-07-03 10:39:53 +00:00
2023-04-19 08:47:31 +00:00
2023-07-26 23:23:26 +00:00
2023-06-27 19:47:04 +00:00
2023-04-10 18:15:12 +00:00
2023-04-12 22:18:54 +00:00
2023-04-12 22:18:54 +00:00
2021-11-02 17:42:52 +00:00
2021-08-16 11:11:04 +00:00
2023-04-10 18:15:12 +00:00
2023-04-10 18:15:12 +00:00
2023-04-10 18:15:12 +00:00
2023-02-21 19:07:57 +00:00
2023-04-10 18:15:12 +00:00
2023-05-11 21:41:01 +00:00
2023-04-12 22:18:54 +00:00
2023-04-10 18:15:12 +00:00
2023-03-06 22:06:59 +00:00
2023-01-09 15:48:57 +00:00
2023-04-26 22:18:51 +00:00
2023-07-27 20:17:17 +00:00
2023-05-10 19:08:23 +00:00
2023-04-10 18:15:12 +00:00
2023-04-10 18:15:12 +00:00
2023-04-20 17:42:06 +00:00
2023-07-12 15:46:27 +00:00
2023-06-29 17:29:48 +00:00
2023-04-10 18:15:12 +00:00
2023-04-10 18:15:12 +00:00
2023-04-10 18:15:12 +00:00
2023-04-10 18:15:12 +00:00
2023-07-10 20:33:33 +00:00
2023-07-10 20:33:33 +00:00
2023-07-10 20:33:33 +00:00
2021-10-05 16:32:40 +00:00
2021-10-05 16:32:40 +00:00
2021-12-15 23:12:19 +00:00
2023-02-20 14:57:57 +00:00
2022-08-03 10:32:46 +00:00
2023-04-12 22:18:54 +00:00
2023-06-24 12:56:12 +00:00
2023-07-06 08:16:47 +00:00
2023-04-17 16:26:35 +00:00
2023-04-12 22:18:54 +00:00
2023-04-12 22:18:54 +00:00
2023-04-12 22:18:54 +00:00
2023-04-12 22:18:54 +00:00
2023-07-28 10:01:53 +00:00
2023-06-23 20:35:00 +00:00
2023-05-11 03:14:27 +00:00
2023-05-11 03:14:27 +00:00
2023-05-11 03:14:27 +00:00
2023-04-10 18:15:12 +00:00
2023-04-10 18:15:12 +00:00
2023-04-12 22:18:54 +00:00
2021-12-15 22:22:36 +00:00
2021-09-02 21:46:35 +00:00
2022-08-05 11:53:37 +00:00
2023-06-23 20:35:00 +00:00
2023-06-23 20:35:00 +00:00
2023-06-20 19:28:18 +00:00
2023-06-21 11:39:50 +00:00
2023-06-06 02:07:58 +00:00
2023-06-21 11:39:50 +00:00
2023-06-28 01:00:18 +00:00
2023-06-20 19:28:18 +00:00
2022-09-10 15:12:35 +00:00
2023-04-21 22:41:28 +00:00
2023-06-06 02:07:58 +00:00
2023-06-07 19:01:51 +00:00
2023-06-16 11:22:38 +00:00
2023-06-16 11:22:38 +00:00