On the surface it seems a little strange: in 1814 my ancestor is listed as an "infant." A year later she is getting married. Seems a little hinky and perhaps immoral or illegal.
And yet it is not.
Someone who is an infant in the eyes of the law is simply not of the age of majority or the age of consent. The person could easily be termed an "infant" one year and old enough to get married the next.
Remember how the law defines a term is often slightly different from how that same term is used in everyday English.