[m-dev.] foreign enum module qualification

Peter Wang novalazy at gmail.com
Fri Oct 4 15:02:52 AEST 2019

On Fri, 4 Oct 2019 13:58:06 +1000 (AEST), Julien Fischer <jfischer at opturion.com> wrote:
> On Fri, 4 Oct 2019, Zoltan Somogyi wrote:
> > Foreign enum pragmas specify a mapping from the names
> > of an enum type's constants to their foreign names. At the moment,
> > we allow programmers to module qualify the names of the constants,
> > but there is not much point in that, since the only valid module name
> > that the qualification may yield is the name of the current module.
> >
> > I would guess that the only reason for allow module qualification
> > on the constant names is to reuse code that handles foreign_export_enums,
> > in which module qualification *does* make sense.
> >
> > Would anyone object if we required the constant names in foreign_enum
> > pragmas to be unqualified? It would remove a potential source
> > of user errors. And even though in *theory* this is a breaking
> > change, in practice, it isn't really, since people tend not to write
> > such obviously redundant qualifications.
> No objection from me.

Nor from me.


More information about the developers mailing list