kernel 0.3.6+6

  • README.md
  • Installing
  • Versions
  • 85

Dart Kernel

Dart Kernel is a small high-level language derived from Dart. It is designed for use as an intermediate format for whole-program analysis and transformations, and to be consumed by codegen and execution backends.

The kernel language has an in-memory representation in Dart and can be serialized as binary or text.

Both the kernel language and its implementations are unstable and are under development.

This package contains the Dart part of the implementation and contains:

  • A transformable IR for the kernel language
  • Serialization of kernel code

Note: The APIs in this package are in an early state; developers should be careful about depending on this package. In particular, there is no semver contract for release versions of this package. Please depend directly on individual versions.

See ast.dart for the in-memory IR, or binary.md for a description of the binary format. For now, the textual format is very ad-hoc and cannot be parsed back in.

Use this package as a library

1. Depend on it

Add this to your package's pubspec.yaml file:


dependencies:
  kernel: ^0.3.6+6

2. Install it

You can install packages from the command line:

with pub:


$ pub get

with Flutter:


$ flutter packages get

Alternatively, your editor might support pub get or flutter packages get. Check the docs for your editor to learn more.

3. Import it

Now in your Dart code, you can use:


import 'package:kernel/kernel.dart';
  
Version Uploaded Documentation Archive
0.3.6+6 Nov 21, 2018 Go to the documentation of kernel 0.3.6+6 Download kernel 0.3.6+6 archive
0.3.6+5 Nov 14, 2018 Go to the documentation of kernel 0.3.6+5 Download kernel 0.3.6+5 archive
0.3.6+4 Nov 14, 2018 Go to the documentation of kernel 0.3.6+4 Download kernel 0.3.6+4 archive
0.3.6+3 Nov 6, 2018 Go to the documentation of kernel 0.3.6+3 Download kernel 0.3.6+3 archive
0.3.6+2 Nov 2, 2018 Go to the documentation of kernel 0.3.6+2 Download kernel 0.3.6+2 archive
0.3.6+1 Oct 25, 2018 Go to the documentation of kernel 0.3.6+1 Download kernel 0.3.6+1 archive
0.3.6 Oct 4, 2018 Go to the documentation of kernel 0.3.6 Download kernel 0.3.6 archive
0.3.5 Sep 12, 2018 Go to the documentation of kernel 0.3.5 Download kernel 0.3.5 archive
0.3.4+2 Oct 4, 2018 Go to the documentation of kernel 0.3.4+2 Download kernel 0.3.4+2 archive
0.3.4+1 Aug 31, 2018 Go to the documentation of kernel 0.3.4+1 Download kernel 0.3.4+1 archive

All 27 versions...

Popularity:
Describes how popular the package is relative to other packages. [more]
96
Health:
Code health derived from static analysis. [more]
97
Maintenance:
Reflects how tidy and up-to-date the package is. [more]
40
Overall:
Weighted score of the above. [more]
85
Learn more about scoring.

We analyzed this package on Nov 22, 2018, and provided a score, details, and suggestions below. Analysis was completed with status completed using:

  • Dart: 2.0.0
  • pana: 0.12.6

Platforms

Detected platforms: Flutter, other

Primary library: package:kernel/kernel.dart with components: io.

Health suggestions

Fix lib/ast.dart. (-2.96 points)

Analysis of lib/ast.dart reported 6 hints, including:

line 4485 col 17: Always override hashCode if overriding ==.

line 4547 col 17: Always override hashCode if overriding ==.

line 4573 col 17: Always override hashCode if overriding ==.

line 4585 col 17: Always override hashCode if overriding ==.

line 4597 col 17: Always override hashCode if overriding ==.

Fix lib/class_hierarchy.dart. (-0.50 points)

Analysis of lib/class_hierarchy.dart reported 1 hint:

line 1408 col 12: Invocation of Iterable<E>.contains with references of unrelated types.

Maintenance issues and suggestions

Running dartdoc failed. (-10 points)

Make sure dartdoc runs without any issues.

Maintain CHANGELOG.md. (-20 points)

Changelog entries help clients to follow the progress in your code.

The description is too short. (-20 points)

Add more detail about the package, what it does and what is its target use case. Try to write at least 60 characters.

Maintain an example. (-10 points)

Create a short demo in the example/ directory to show how to use this package. Common file name patterns include: main.dart, example.dart or you could also use kernel.dart.

Dependencies

Package Constraint Resolved Available
Direct dependencies
Dart SDK >=2.0.0-dev.48.0 <3.0.0
args >=0.13.4 <2.0.0 1.5.1
logging ^0.11.2 0.11.3+2
package_config ^1.0.0 1.0.5
path ^1.3.9 1.6.2
Transitive dependencies
charcode 1.1.2
Dev dependencies
front_end 0.1.6+6
stack_trace ^1.6.6
test ^1.3.4
test_reflective_loader ^0.1.0
testing