@@ -101,6 +101,7 @@ pub(super) enum CallNodePositionType {
101
101
102
102
pub ( super ) fn call_node_position_type ( node : & Node , point : Point ) -> CallNodePositionType {
103
103
match node. node_type ( ) {
104
+ NodeType :: Arguments => return CallNodePositionType :: Name ,
104
105
NodeType :: Anonymous ( kind) if kind == "(" => {
105
106
if point. is_before_or_equal ( node. start_position ( ) ) {
106
107
// Before the `(`
@@ -434,17 +435,6 @@ mod tests {
434
435
let document = Document :: new ( & text, None ) ;
435
436
let context = DocumentContext :: new ( & document, point, None ) ;
436
437
437
- // On `main`, this passes
438
- // assert_eq!(
439
- // context.node.node_type(),
440
- // NodeType::Anonymous(String::from("("))
441
- // );
442
-
443
- // On this pr, `(`, doesn't contain the user's cursor, so instead it selects
444
- // the surrounding `Arguments` node
445
- assert_eq ! ( context. node. node_type( ) , NodeType :: Arguments ) ;
446
-
447
- // On `main`, this passes, and this should also still pass on this PR, but currently does not
448
438
assert_eq ! (
449
439
call_node_position_type( & context. node, context. point) ,
450
440
CallNodePositionType :: Name
0 commit comments