go/analysis/passes/modernize/testdata/src/minmax/userdefined/notuserparams/notuserparams.go
raw| 1 | package notuserparams |
| 2 | |
| 3 | // User-defined max with correct logic but wrong vars - should NOT be removed |
| 4 | func max(a, b int) int { |
| 5 | if a < 5 { |
| 6 | return a |
| 7 | } else { |
| 8 | return 5 |
| 9 | } |
| 10 | } |
| 11 | |
| 12 | // User-defined min with correct logic but wrong vars - should NOT be removed |
| 13 | func min(a, b int) int { |
| 14 | if 5 < b { |
| 15 | return 5 |
| 16 | } else { |
| 17 | return b |
| 18 | } |
| 19 | } |