syntax: consolidate function parsing in item.rs
This commit is contained in:
parent
1721c9685b
commit
4a0c487d1b
3 changed files with 491 additions and 487 deletions
|
@ -1,4 +1,5 @@
|
|||
use super::{Parser, PResult, PathStyle, PrevTokenKind, TokenType};
|
||||
use super::item::ParamCfg;
|
||||
|
||||
use crate::{maybe_whole, maybe_recover_from_interpolated_ty_qpath};
|
||||
use crate::ptr::P;
|
||||
|
@ -281,7 +282,7 @@ impl<'a> Parser<'a> {
|
|||
let unsafety = self.parse_unsafety();
|
||||
let abi = self.parse_extern_abi()?;
|
||||
self.expect_keyword(kw::Fn)?;
|
||||
let cfg = super::ParamCfg {
|
||||
let cfg = ParamCfg {
|
||||
is_self_allowed: false,
|
||||
allow_c_variadic: true,
|
||||
is_name_required: |_| false,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue