From zoltan.somogyi at runbox.com Fri Apr 3 08:15:26 2026 From: zoltan.somogyi at runbox.com (Zoltan Somogyi) Date: Fri, 03 Apr 2026 08:15:26 +1100 (AEDT) Subject: [m-dev.] special treatment of undefined type_ctors in foreign_export_enum pragmas Message-ID: Normally, if any type_ctor reference in a module refers to an undefined type, we stop compilation early, before the typecheck pass. We make an exception for type_ctors in foreign_export_enum_pragmas: if one of *these* is undefined, we go on with the rest of the compilation. I am working on a change (recording the error messages for e.g. undefined types next to the set of undefined type_ctors, with the ultimate aim of ensuring that we never just stop due to "undefined types" without actually printing the messages about those types) for which this is inconvenient. I *could* preserve this behavior, but do not see any point in doing so, since this special treatment buys users only a tiny bit of convenience, and only once in a blue moon. I therefore propose ending this special treatment. Does anyone object? If you do, please register this objection in the next 12 hours or so, since I would like to work on this then. Zoltan. From jfischer at opturion.com Fri Apr 3 12:56:34 2026 From: jfischer at opturion.com (Julien Fischer) Date: Fri, 3 Apr 2026 12:56:34 +1100 Subject: [m-dev.] special treatment of undefined type_ctors in foreign_export_enum pragmas In-Reply-To: References: Message-ID: On Fri, 3 Apr 2026 at 08:47, Zoltan Somogyi wrote: > > Normally, if any type_ctor reference in a module refers to an undefined type, > we stop compilation early, before the typecheck pass. We make an exception > for type_ctors in foreign_export_enum_pragmas: if one of *these* is undefined, > we go on with the rest of the compilation. > > I am working on a change (recording the error messages for e.g. undefined types > next to the set of undefined type_ctors, with the ultimate aim of ensuring that > we never just stop due to "undefined types" without actually printing the messages > about those types) for which this is inconvenient. I *could* preserve this behavior, > but do not see any point in doing so, since this special treatment buys users > only a tiny bit of convenience, and only once in a blue moon. I therefore propose > ending this special treatment. > > Does anyone object? If you do, please register this objection in the next 12 hours > or so, since I would like to work on this then. No objection from me. Julien.