瀏覽代碼

Fix PacketMeta doc issues

ssrlive 1 年之前
父節點
當前提交
a051f8b261
共有 1 個文件被更改,包括 2 次插入2 次删除
  1. 2 2
      src/phy/mod.rs

+ 2 - 2
src/phy/mod.rs

@@ -149,8 +149,8 @@ pub use self::tuntap_interface::TunTapInterface;
 /// default values and then set the fields you want. This makes adding metadata
 /// fields a non-breaking change.
 ///
-/// ```rust,ignore
-/// let mut meta = PacketMeta::new();
+/// ```rust
+/// let mut meta = smoltcp::phy::PacketMeta::default();
 /// meta.id = 15;
 /// ```
 #[cfg_attr(feature = "defmt", derive(defmt::Format))]