kernel 0.3.9

  • README.md
  • Installing
  • Versions
  • 87

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.9

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.9 Jan 16, 2019 Go to the documentation of kernel 0.3.9 Download kernel 0.3.9 archive
0.3.8 Dec 19, 2018 Go to the documentation of kernel 0.3.8 Download kernel 0.3.8 archive
0.3.7 Nov 29, 2018 Go to the documentation of kernel 0.3.7 Download kernel 0.3.7 archive
0.3.6+9 Dec 11, 2018 Go to the documentation of kernel 0.3.6+9 Download kernel 0.3.6+9 archive
0.3.6+8 Nov 29, 2018 Go to the documentation of kernel 0.3.6+8 Download kernel 0.3.6+8 archive
0.3.6+7 Nov 28, 2018 Go to the documentation of kernel 0.3.6+7 Download kernel 0.3.6+7 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

All 33 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]
50
Overall:
Weighted score of the above. [more]
87
Learn more about scoring.

We analyzed this package on Jan 16, 2019, and provided a score, details, and suggestions below. Analysis was completed with status completed using:

  • Dart: 2.1.0
  • pana: 0.12.10

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 4520 col 17: Always override hashCode if overriding ==.

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

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

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

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

Maintenance issues and suggestions

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
path ^1.3.9 1.6.2
Dev dependencies
expect
front_end 0.1.9
stack_trace ^1.6.6
test ^1.3.4
test_reflective_loader ^0.1.0
testing