Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 1 addition & 19 deletions packages/pigeon/CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,16 +6,6 @@ Pigeon is a code generation tool that adds type safety to Flutter’s Platform
Channels. This document serves as an overview of how it functions to help
people who would like to contribute to the project.

## State Diagram

Pigeon generates a temporary file in its _LaunchIsolate_, the isolate that is
spawned to run `main()`, then launches another isolate, _PigeonIsolate_, that
uses `dart:mirrors` to parse the generated file, creating an
[AST](https://en.wikipedia.org/wiki/Abstract_syntax_tree), then running code
generators with that AST.

![State Diagram](./doc/pigeon_state.png)
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should delete https://github.com/srawlins/flutter-packages/tree/main/packages/pigeon/doc as well, since this was the only reference to it.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done.


## Source Index

* [ast.dart](./lib/src/ast.dart) - The data structure for representing the Abstract Syntax Tree.
Expand All @@ -37,7 +27,7 @@ generators with that AST.

## Testing Overview

Pigeon has 3 types of tests, you'll find them all in
Pigeon has 3 types of tests; you'll find them all in
[test.dart](./tool/test.dart).

* Unit tests - These are the fastest tests that are just typical unit tests,
Expand Down Expand Up @@ -73,11 +63,3 @@ void main(List<String> args, SendPort sendPort) async {
```

This is how `dart:mirrors` gets access to the supplied Pigeon file.

## Imminent Plans

* Migrate to Dart Analyzer for AST generation ([issue
78818](https://github.com/flutter/flutter/issues/78818)) - We might have
reached the limitations of using dart:mirrors for parsing the Dart files.
That package has been deprecated and it doesn't support null-safe annotations.
We should migrate to using the Dart Analyzer as the front-end parser.
Binary file removed packages/pigeon/doc/pigeon_state.png
Binary file not shown.
60 changes: 0 additions & 60 deletions packages/pigeon/doc/pigeon_state.puml

This file was deleted.

Loading