I feel like a suit is over doing it and I'd have to go out and buy one. It also seems like, from what I've read online, software developer dress code is more business casual than formal. But this is a law firm we're talking about which kind of implies formality to me so I'm torn.
While most software development positions are business casual or just casual, it's different because you are going for an interview. You want to show you have made an effort.
The best thing to do is ask the recruiter or whoever invited you to the interview what you should wear.
As it's a law firm I would immediately think a suit is a must. There is a belief that wearing a suit will go against you at some software companies but I don't believe that. Even if it's a causal dress company you wont be disregarded for wearing a suit, but you can be disregarded for not dressing smart enough.
Ultimately you have to try and understand the company and wear what you think is most appropriate.
If you go through a recruiter, ask the recruiter. If not, call their receptionist or call any contact that you have.
As a rule, you should dress a bit better than you are willing to dress every day. If this is a firm that requires everyone to come in a suit, and you are not willing to do that, then business casual wont get you the job, but that is Ok if you wouldn't have wanted the job anyway.