dotnet / csharplang

The official repo for the design of the C# programming language
11.02k stars 1.01k forks source link

Champion: relax ordering constraints around `ref` and `partial` modifiers on type declarations #946

Open agocke opened 6 years ago

agocke commented 6 years ago

Currently, partial must appear directly before struct, class, or another type declaration keyword. If the type is a ref struct, ref must appear immediately before partial or struct. It seems likely that various other keywords could be used to disambiguate these contextual modifiers and allow us to relax the constraints on where partial and ref can appear in the modifier list.

See https://github.com/dotnet/csharplang/blob/master/meetings/2017/LDM-2017-12-04.md

CyrusNajmabadi commented 6 years ago

Note: i've looked at https://github.com/dotnet/csharplang/blob/master/meetings/2017/LDM-2017-12-04.md, but i can't find where in it it refers to this issue. Can you link/copy the appropriate section?

Thanks!

Joe4evr commented 6 years ago

Can restrictions around partial just be relaxed entirely? I'd like it if partial abstract class worked just the same as abstract partial class.

Joe4evr commented 2 years ago

See https://github.com/dotnet/csharplang/blob/master/meetings/2017/LDM-2017-12-04.md

So that link does not talk about partial anywhere (as @CyrusNajmabadi noted), so I did a quick search for the paper trail myself: