The in general hard problem of computing weight distributions of linear cod
es is considered for the special class of algebraic-geometric codes, define
d by Goppa in the early eighties. Known results restrict to codes from elli
ptic curves. We obtain results for curves of higher genus by expressing the
weight distributions in terms of L-series. The results include general pro
perties of weight distributions, a method to describe and compute weight di
stributions, and worked out examples for curves of genus two and three.