use vec![] for the get_status vector
This commit is contained in:
parent
6dc11526d8
commit
fe07344cb4
1 changed files with 4 additions and 4 deletions
|
|
@ -37,14 +37,14 @@ macro_rules! build_parser_type_enum {
|
||||||
|
|
||||||
impl ParserTypes {
|
impl ParserTypes {
|
||||||
pub fn get_status() -> Vec<ProtocolStatus> {
|
pub fn get_status() -> Vec<ProtocolStatus> {
|
||||||
let mut protos = Vec::new();
|
vec![
|
||||||
$(
|
$(
|
||||||
#[cfg(feature = $feat)]
|
#[cfg(feature = $feat)]
|
||||||
protos.push(ProtocolStatus::Enabled($feat));
|
ProtocolStatus::Enabled($feat),
|
||||||
#[cfg(not(feature = $feat))]
|
#[cfg(not(feature = $feat))]
|
||||||
protos.push(ProtocolStatus::Disabled($feat));
|
ProtocolStatus::Disabled($feat),
|
||||||
)*
|
)*
|
||||||
protos
|
]
|
||||||
}
|
}
|
||||||
|
|
||||||
pub fn announce() {
|
pub fn announce() {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue