Skip to content
Snippets Groups Projects
Commit a5d8025b authored by Alisher Alikhodjaev's avatar Alisher Alikhodjaev
Browse files

The TryFrom should be included unconditionally

Bug: 197333653
Test: build libbt_packets
Change-Id: Ifcfee5b3f1a03d90e0351f379180bbf207c574d1
parent 52032903
No related branches found
No related tags found
No related merge requests found
......@@ -25,7 +25,7 @@ void generate_rust_packet_preamble(std::ostream& s) {
use bytes::{Bytes, BytesMut, BufMut};
use num_derive::{FromPrimitive, ToPrimitive};
use num_traits::{FromPrimitive, ToPrimitive};
use std::convert::TryInto;
use std::convert::{TryFrom, TryInto};
use std::fmt;
use thiserror::Error;
use std::sync::Arc;
......@@ -138,7 +138,6 @@ bool generate_rust_source_one_file(
if (opcode_index != nullptr && opcode != nullptr) {
opcode_index->try_from_enum_ = opcode;
out_file << "use std::convert::TryFrom;";
}
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment