We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
This type signature is not parsed correctly, because we can't parse nested types.
function verifyToken(token: string): string | jwt.JwtPayload {} -------------- ^ | This is the issue
This gets parsed as follows by tree-sitter (Paste into here: https://tree-sitter.github.io/tree-sitter/playground):
[program](https://tree-sitter.github.io/tree-sitter/playground#) [0, 0] - [1, 0] [function_declaration](https://tree-sitter.github.io/tree-sitter/playground#) [0, 0] - [0, 63] name: [identifier](https://tree-sitter.github.io/tree-sitter/playground#) [0, 9] - [0, 20] parameters: [formal_parameters](https://tree-sitter.github.io/tree-sitter/playground#) [0, 20] - [0, 35] [required_parameter](https://tree-sitter.github.io/tree-sitter/playground#) [0, 21] - [0, 34] pattern: [identifier](https://tree-sitter.github.io/tree-sitter/playground#) [0, 21] - [0, 26] type: [type_annotation](https://tree-sitter.github.io/tree-sitter/playground#) [0, 26] - [0, 34] [predefined_type](https://tree-sitter.github.io/tree-sitter/playground#) [0, 28] - [0, 34] return_type: [type_annotation](https://tree-sitter.github.io/tree-sitter/playground#) [0, 35] - [0, 60] [union_type](https://tree-sitter.github.io/tree-sitter/playground#) [0, 37] - [0, 60] [predefined_type](https://tree-sitter.github.io/tree-sitter/playground#) [0, 37] - [0, 43] [nested_type_identifier](https://tree-sitter.github.io/tree-sitter/playground#) [0, 46] - [0, 60] module: [identifier](https://tree-sitter.github.io/tree-sitter/playground#) [0, 46] - [0, 49] name: [type_identifier](https://tree-sitter.github.io/tree-sitter/playground#) [0, 50] - [0, 60] body: [statement_block](https://tree-sitter.github.io/tree-sitter/playground#) [0, 61] - [0, 63]
Note the nested_type_identifier section near the end.
nested_type_identifier
This should be quite easy to add to https://github.com/Doctave/dossier/blob/main/dossier-ts/src/types.rs.
Then we need to ensure that we can resolve these types to their implementations. That may require a bit more thinking.
The text was updated successfully, but these errors were encountered:
No branches or pull requests
This type signature is not parsed correctly, because we can't parse nested types.
This gets parsed as follows by tree-sitter (Paste into here: https://tree-sitter.github.io/tree-sitter/playground):
Note the
nested_type_identifier
section near the end.The fix
This should be quite easy to add to https://github.com/Doctave/dossier/blob/main/dossier-ts/src/types.rs.
Then we need to ensure that we can resolve these types to their implementations. That may require a bit more thinking.
The text was updated successfully, but these errors were encountered: