Interpolation struct names and location
Atila Neves
atila.neves at gmail.com
Thu Feb 15 09:28:55 UTC 2024
On Wednesday, 14 February 2024 at 12:59:34 UTC, Paul Backus wrote:
> On Wednesday, 14 February 2024 at 05:30:47 UTC, Steven
> Schveighoffer wrote:
>> [...]
>
> I think putting them in `core.interpolation` instead of
> `object.d` is fine. Having to `import core.interpolation` when
> you write a function that takes an interpolation sequence is no
> worse than having to `import core.vararg` when you write a
> variadic function.
>
> Normally, my suggestion would be to not repeat the module name
> in the type name, and just call these
> `core.interpolation.Header`, `core.interpolation.Footer`,
> `core.interpolation.Literal`, and
> `core.interpolation.Expression`. However, the names of these
> types are going to show up in user-facing error messages
> without the module name attached, so having some kind of prefix
> to distinguish them makes sense.
This can be fixed by using the fully qualified name.
More information about the Digitalmars-d
mailing list