-
Notifications
You must be signed in to change notification settings - Fork 86
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
support imports and exports in the formatter (#1692)
This is one of the changes required for the imports/exports feature work, and this is particularly important for the standard library, which will make extensive use of long export lists and needs to be formatted well. This PR adds a new context, similar to the existing open/close delim contexts, that is defined by `import` or `export`...`;`. If there is a newline after the `import` or `export` keyword, then we format with newlines. Otherwise, puts it all on one line. See the tests for examples. before: ```qsharp export Foo, Bar, Baz; ``` after: ```qsharp export Foo, Bar, Baz; ``` OR, in single-line mode, ```qsharp export Foo, Bar, Baz; ```
- Loading branch information
Showing
2 changed files
with
232 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters