You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* Operation/function declarations with type parameters and class constraints (`<'T : Eq + Add>`, `Exp['T]`), plus the functors `is Adj + Ctl`
15
+
* Lambdas (`->`, `=>`), partial application, ternary (`cond ? a | b`), and the full operator set (arithmetic, comparison, logical, bitwise `&&& ||| ^^^ ~~~ <<< >>>`, ranges `..`/`...`, copy-update `w/ ... <-`)
16
+
* Numeric literals in decimal, hex (`0xFF`), binary (`0b1010`), octal (`0o52`), `BigInt` (`42L`), exponent (`1.0e-3`) and digit-separator (`1_000`) forms
17
+
* Interpolated strings (`$"...{expr}..."`) with tokenized expression holes
18
+
* Intrinsic quantum operations highlighted as quantum operations while still tokenizing their arguments
19
+
20
+
The behaviour is pinned by an extensive unit-test suite; the tests can additionally be run against a checkout of the official [`microsoft/qdk`](https://github.com/microsoft/qdk) samples by pointing the `QDK_SAMPLES` environment variable at its `samples/` directory.
21
+
7
22
## Build and Development
8
23
9
24
To contribute, clone the repo and run (requires Node.js and `npm` to be installed on the dev machine)
10
25
11
26
*`npm install` to install all dependencies
12
-
* Run `npm run compile` to build and run tests
13
-
* Run `npm run test` to run only tests
27
+
* Run `npm run build` to regenerate the grammar outputs from the YAML source
28
+
* Run `npm test` to build the grammar and run the unit tests
14
29
15
30
The source grammar is located at `src/qsharp.tmLanguage.yml` and is the core file to be maintained.
31
+
The build (`build.js`) converts it into the two output files below; the tests tokenize
32
+
Q# snippets with `vscode-textmate` and assert on the resulting scopes.
0 commit comments