Dress code

If something is not specifically indicated in the dress code, is it petty to point out an infraction? We have a pretty relaxed atmosphere in our office and I wore jeggings with a waist-length top and my boss called me out on it because my top wasn’t long enough. nothing in the dress code about that. Was I in the wrong?

I know i can never be “over-dressed”.