Skip to content

[ddc] Generate code to call specialized as helpers from package:_rti #60056

@nshahan

Description

@nshahan

The shared rti library contains some specialized cast helper methods for some core types. ex:

int _asInt(Object? object) {

int? _asIntQ(dynamic object) {

DDC should generate code to invoke these methods directly when possible.

These can replace some existing calls to methods that are a legacy from the old type system allowing for some cleanup. ex:

asNullableInt(obj) => obj == null ? null : asInt(obj);

Metadata

Metadata

Assignees

Labels

P3A lower priority bug or feature requestarea-web-jsIssues related to JavaScript support for Dart Web, including DDC, dart2js, and JS interop.web-dev-compiler

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions