I don’t think there’s any advantage. It’s just a difference in syntax.
I’ve never used HoundCI, but I believe it makes recommendations based on this Ruby style guide:
That style guide says: “Prefer %i to the literal array syntax when you need an array of symbols”.
Again, I think this is just a syntax difference. HoundCI is just making a style recommendation to be consistent with that style guide. Really there’s no difference between [:a, :b] and %i(a b)
Just like there’s no difference between and Array.new
Hi @yevgenko, everything @chris_sun1 said sounds right to me. Just a different syntax, not necessarily better (although it is easier to type, which is nice!) A major goal when using Hound is to encourage a consistent syntax which does not necessarily imply that the particular style Hound is enforcing is “better”.