@@ -8,7 +8,7 @@ pub enum BbcodeNode<'a> {
88 Text ( Cow < ' a , str > ) ,
99}
1010
11- impl < ' a > Display for BbcodeNode < ' a > {
11+ impl Display for BbcodeNode < ' _ > {
1212 fn fmt ( & self , f : & mut std:: fmt:: Formatter < ' _ > ) -> std:: fmt:: Result {
1313 match self {
1414 BbcodeNode :: Tag ( node) => node. fmt ( f) ,
@@ -26,7 +26,7 @@ pub struct BbcodeTag<'a> {
2626 simple_param : Option < Cow < ' a , str > > ,
2727
2828 /// Complex parameters, e.g. the map `value1` -> `xxx`, `value2` -> `yyy` for `[tag value1=”xxx” value2=”yyy”]something[/tag]`.
29- complex_params : HashMap < Cow < ' a , str > , Cow < ' a , str > > ,
29+ complex_params : HashMap < & ' a str , Cow < ' a , str > > ,
3030
3131 /// The child nodes (or text) contained inside this node.
3232 children : Vec < Arc < BbcodeNode < ' a > > > ,
@@ -45,7 +45,7 @@ impl<'a> BbcodeTag<'a> {
4545
4646 /// Add a simple parameter to the tag.
4747 #[ cfg( test) ]
48- pub fn with_simple_param < P : Into < String > > ( mut self , tag_param : P ) -> Self {
48+ pub fn with_simple_param < P : Into < Cow < ' a , str > > > ( mut self , tag_param : P ) -> Self {
4949 self . simple_param = Some ( tag_param. into ( ) ) ;
5050 self
5151 }
0 commit comments