When I tried to use numbers as IDs in .xml menu files the compiler said "heck no", and refused to compile resources. I think the same should be applied to code-generated menus, because I spent a lot of time trying to debug the whole thing, or just throw an exception at runtime, so I will at least know what died. I think the first option is better.