Stoichiometry of Ce–Mg compounds