fix(tvix/eval): address useless_format clippy warn
This CL address clippy warnings related to use of 'format!' macro to return unmodified 'String'. Change-Id: I88726e59d8f39f6a455a8c1f48075b52d167e489 Signed-off-by: Aaqa Ishtyaq <aaqaishtyaq@gmail.com> Reviewed-on: https://cl.tvl.fyi/c/depot/+/7804 Reviewed-by: flokli <flokli@flokli.de> Tested-by: BuildkiteCI
This commit is contained in:
		
							parent
							
								
									88f9503057
								
							
						
					
					
						commit
						9382afdb0d
					
				
					 1 changed files with 6 additions and 13 deletions
				
			
		| 
						 | 
					@ -68,7 +68,8 @@ impl EvalWarning {
 | 
				
			||||||
            }
 | 
					            }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
            WarningKind::UselessInherit => {
 | 
					            WarningKind::UselessInherit => {
 | 
				
			||||||
                format!("inherit does nothing (this variable already exists with the same value)")
 | 
					                "inherit does nothing (this variable already exists with the same value)"
 | 
				
			||||||
 | 
					                    .to_string()
 | 
				
			||||||
            }
 | 
					            }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
            WarningKind::UnusedBinding => {
 | 
					            WarningKind::UnusedBinding => {
 | 
				
			||||||
| 
						 | 
					@ -94,21 +95,13 @@ impl EvalWarning {
 | 
				
			||||||
                format!("useless operation on boolean: {}", msg)
 | 
					                format!("useless operation on boolean: {}", msg)
 | 
				
			||||||
            }
 | 
					            }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
            WarningKind::DeadCode => {
 | 
					            WarningKind::DeadCode => "this code will never be executed".to_string(),
 | 
				
			||||||
                format!("this code will never be executed")
 | 
					 | 
				
			||||||
            }
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
            WarningKind::EmptyInherit => {
 | 
					            WarningKind::EmptyInherit => "this `inherit` statement is empty".to_string(),
 | 
				
			||||||
                format!("this `inherit` statement is empty")
 | 
					 | 
				
			||||||
            }
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
            WarningKind::EmptyLet => {
 | 
					            WarningKind::EmptyLet => "this `let`-expression contains no bindings".to_string(),
 | 
				
			||||||
                format!("this `let`-expression contains no bindings")
 | 
					 | 
				
			||||||
            }
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
            WarningKind::UselessParens => {
 | 
					            WarningKind::UselessParens => "these parenthesis can be removed".to_string(),
 | 
				
			||||||
                format!("these parenthesis can be removed")
 | 
					 | 
				
			||||||
            }
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
            WarningKind::NotImplemented(what) => {
 | 
					            WarningKind::NotImplemented(what) => {
 | 
				
			||||||
                format!("feature not yet implemented in tvix: {}", what)
 | 
					                format!("feature not yet implemented in tvix: {}", what)
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue