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
When a Python lambda does not have an parameter list, the current TSG fails.
The rules currently fail for the following CST.
(lambda [207, 32] - [207, 69] body: (call [207, 40] - [207, 69] function: (attribute [207, 40] - [207, 53] object: (identifier [207, 40] - [207, 48]) attribute: (identifier [207, 49] - [207, 53])) arguments: (argument_list [207, 53] - [207, 69] (list_splat [207, 54] - [207, 68] (attribute [207, 55] - [207, 68] object: (identifier [207, 55] - [207, 63]) attribute: (identifier [207, 64] - [207, 68]))))))))))))))
[ (function_definition -- parameters: (_) @params ++ parameters: (_)? @params body: (_) @body ) @func (lambda -- parameters: (_) @params ++ parameters: (_)? @params body: (_) @body )@func ] { node @func.call node return_value node drop_scope edge @func.call -> return_value ++ if some @params { edge @body.before_scope -> @params.after_scope ++ } edge @body.before_scope -> drop_scope edge drop_scope -> @func.bottom attr (drop_scope) type = "drop_scopes" attr (@func.call) pop_scoped_symbol = "()" ++ if some @params { edge @params.before_scope -> JUMP_TO_SCOPE_NODE ++ } attr (return_value) is_exported let @func.function_returns = return_value }
The text was updated successfully, but these errors were encountered:
No branches or pull requests
When a Python lambda does not have an parameter list, the current TSG fails.
Example
The rules currently fail for the following CST.
Suggested change
The text was updated successfully, but these errors were encountered: