Skip to main content
7 events
when toggle format what by license comment
17 hours ago answer added Max timeline score: 0
19 hours ago comment added Max Ok, it's for a client I'm working for and if I'd do that I'd need to justify the extra setup needed to achieve this "nice to have". So should there be no built-in way to do this check, I'll probably skip it.
19 hours ago comment added Jon Skeet I think I'd misinterpreted the option - ignore me. (As for a solution to the actual problem - I'm not sure there's anything in editorconfig for this, but you could write your own Roslyn analyzer easily enough, or just a unit test which you could reuse across assemblies.)
19 hours ago comment added Max Not sure I understand, here is what I want to achieve: 1. All C# should have a namspace set explicitly (i.e. not possible to have a C# file missing namespace declaration) 2. All namespace declarations should be file scoped 3. All namespaces should match file structure With the current setup I solve 2 and 3, but not 1.
20 hours ago comment added Jon Skeet Out of interest, why would you want to prevent file-scoped namespaces? That does explicitly set a namespace, so what do you object to about it? (Personally I love getting rid of completely unnecessary level of indentation...)
21 hours ago history edited marc_s CC BY-SA 4.0
added 10 characters in body; edited title
22 hours ago history asked Max CC BY-SA 4.0