Polyesters derived from hydroxycarboxylic acids or from polycarboxylic acids and polyhydroxy compounds