cca6298498
Unlike other calls from Dynamic Modules, dynamic calls cannot be validated entirely at compile time. While we check that the selector used matches a selector that was allowed (either because a method with that selector name was exposed as dynamically callable or because the selector was allowlisted during bytecode compilation), the compiler doesn't know statically whether the target of the call is exposed. In prior changes we modified the annotator to add a pragma indicating whether a member is dynamically-callable or implicitly-dynamically-callable. Here we use that information to set a bit on functions and their corresponding dynamic invocation forwarders, which is verified by the interpreter to make sure the dynamic call is still allowed. TEST=none yet - will be added in subsequent CL (see CL chain) Bug: b/448095881 Change-Id: I27acb4e690a68e08fe1f1ca94e0d77cc7dc4d11e Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/498300 Reviewed-by: Slava Egorov <vegorov@google.com> Reviewed-by: Alexander Markov <alexmarkov@google.com> Auto-Submit: Sigmund Cherem <sigmund@google.com> Commit-Queue: Sigmund Cherem <sigmund@google.com>
77 lines
2.1 KiB
YAML
77 lines
2.1 KiB
YAML
# Copyright (c) 2024, the Dart project authors. Please see the AUTHORS file
|
|
# for details. All rights reserved. Use of this source code is governed by a
|
|
# BSD-style license that can be found in the LICENSE file.
|
|
|
|
extendable:
|
|
- library: 'dart:async'
|
|
- library: 'dart:cli'
|
|
- library: 'dart:collection'
|
|
- library: 'dart:concurrent'
|
|
- library: 'dart:convert'
|
|
- library: 'dart:core'
|
|
- library: 'dart:developer'
|
|
- library: 'dart:ffi'
|
|
- library: 'dart:io'
|
|
- library: 'dart:isolate'
|
|
- library: 'dart:math'
|
|
- library: 'dart:nativewrappers'
|
|
- library: 'dart:typed_data'
|
|
- library: 'dart:vmservice_io'
|
|
|
|
can-be-overridden:
|
|
- library: 'dart:async'
|
|
- library: 'dart:cli'
|
|
- library: 'dart:collection'
|
|
- library: 'dart:concurrent'
|
|
- library: 'dart:convert'
|
|
- library: 'dart:core'
|
|
- library: 'dart:developer'
|
|
- library: 'dart:ffi'
|
|
- library: 'dart:io'
|
|
- library: 'dart:isolate'
|
|
- library: 'dart:math'
|
|
- library: 'dart:nativewrappers'
|
|
- library: 'dart:typed_data'
|
|
- library: 'dart:vmservice_io'
|
|
|
|
callable:
|
|
- library: 'dart:async'
|
|
- library: 'dart:cli'
|
|
- library: 'dart:collection'
|
|
- library: 'dart:concurrent'
|
|
- library: 'dart:convert'
|
|
- library: 'dart:core'
|
|
- library: 'dart:developer'
|
|
- library: 'dart:ffi'
|
|
- library: 'dart:io'
|
|
- library: 'dart:isolate'
|
|
- library: 'dart:math'
|
|
# Explicitly add public members of _RectangleBase because they are inherited
|
|
# by Rectangle/MutableRectangle.
|
|
- library: 'dart:math'
|
|
class: '_RectangleBase'
|
|
- library: 'dart:nativewrappers'
|
|
- library: 'dart:typed_data'
|
|
- library: 'dart:vmservice_io'
|
|
- library: 'dart:_internal'
|
|
member: 'extractTypeArguments'
|
|
|
|
dynamically-callable:
|
|
- library: 'dart:async'
|
|
- library: 'dart:cli'
|
|
- library: 'dart:collection'
|
|
- library: 'dart:concurrent'
|
|
- library: 'dart:convert'
|
|
- library: 'dart:core'
|
|
- library: 'dart:core'
|
|
class: '_Closure'
|
|
member: 'get:call'
|
|
- library: 'dart:developer'
|
|
- library: 'dart:ffi'
|
|
- library: 'dart:io'
|
|
- library: 'dart:isolate'
|
|
- library: 'dart:math'
|
|
- library: 'dart:nativewrappers'
|
|
- library: 'dart:typed_data'
|
|
- library: 'dart:vmservice_io'
|