To many legal scholars, and to most lay people, the actual law is the spirit, the letter is just there to help note down what the spirit was.
If someone thinks they are safe to ignore the spirit of a law because of a quirk of how it is worded, they will often find they are wrong, and have charges brought against them anyway, and lose at trial and any number of appellate courts. Conversely, if someone is convicted based on a technicality where they broke the letter of the law, but not the spirit, that conviction is very likely to be overturned on appeal.
Of course, the spirit and the letter of the law can't be arbitrarily divorced from one another. One can't claim that the letter of the law says "you shall not kill", but the spirit of the law is that it's ok to kill but only on the full moon. But if a law says "don't lie to prosecutors", and they ask me what I did on some day, and I tell them X and Y and don't mention Z, I won't be able to claim that the law didn't techniclaly say not to omit information.
If someone thinks they are safe to ignore the spirit of a law because of a quirk of how it is worded, they will often find they are wrong, and have charges brought against them anyway, and lose at trial and any number of appellate courts. Conversely, if someone is convicted based on a technicality where they broke the letter of the law, but not the spirit, that conviction is very likely to be overturned on appeal.
Of course, the spirit and the letter of the law can't be arbitrarily divorced from one another. One can't claim that the letter of the law says "you shall not kill", but the spirit of the law is that it's ok to kill but only on the full moon. But if a law says "don't lie to prosecutors", and they ask me what I did on some day, and I tell them X and Y and don't mention Z, I won't be able to claim that the law didn't techniclaly say not to omit information.