diff options
author | Joshua Nelson <[email protected]> | 2020-01-12 15:19:17 +0000 |
---|---|---|
committer | Joshua Nelson <[email protected]> | 2020-01-12 15:25:41 +0000 |
commit | c3ac2c93fb446329b09882ef452fd6820290bfc5 (patch) | |
tree | 44734cc34641cfab04cb1c71611ee0a299a90c96 /crates/ra_syntax/test_data/parser/inline/ok/0152_arg_list.rs | |
parent | f7a7092d691aea5c254412d9fd4b3f76a355f11f (diff) |
Allow attributes before function arguments
This adds support for function calls of the form:
```rust
(
#[attr(...)] 1.2,
#[attr_one(...)]
#[attr_two(...)]
1.5,
... etc ...
)
```
Closes https://github.com/rust-analyzer/rust-analyzer/issues/2801
Diffstat (limited to 'crates/ra_syntax/test_data/parser/inline/ok/0152_arg_list.rs')
-rw-r--r-- | crates/ra_syntax/test_data/parser/inline/ok/0152_arg_list.rs | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/crates/ra_syntax/test_data/parser/inline/ok/0152_arg_list.rs b/crates/ra_syntax/test_data/parser/inline/ok/0152_arg_list.rs new file mode 100644 index 000000000..a4009b392 --- /dev/null +++ b/crates/ra_syntax/test_data/parser/inline/ok/0152_arg_list.rs | |||
@@ -0,0 +1,9 @@ | |||
1 | fn assert_float(s: &str, n: f64) {} | ||
2 | fn foo() { | ||
3 | assert_float( | ||
4 | "1.797693134862315708e+308L", | ||
5 | #[allow(clippy::excessive_precision)] | ||
6 | #[allow(dead_code)] | ||
7 | 1.797_693_134_862_315_730_8e+308, | ||
8 | ); | ||
9 | } | ||