-
Notifications
You must be signed in to change notification settings - Fork 28
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Disallowed from a.* to a.b.* causes a.b.c->a.b.c to throw a warning #49
Comments
Sorry, I don't understand your issue clearly. I've just created a unit test for the situation that you've described in the issue title but I cannot reproduce the problem. NsDepCop/source/NsDepCop.Core.Test/Implementation/Analysis/TypeDependencyValidatorTests.cs Lines 123 to 130 in e56565c
Also, the implementation of the TypeDependencyValidator explicitly starts with allowing all same-namespace references, so NsDepCop/source/NsDepCop.Core/Implementation/Analysis/TypeDependencyValidator.cs Lines 32 to 36 in e56565c
So could you give me a complete example so I can reproduce your problem? |
Oh, I think I understand now. So your problem is that a disallowed rule is stronger than the ChildCanDependOnParentImplicitly flag, is that right? NsDepCop/source/NsDepCop.Core.Test/Implementation/Analysis/TypeDependencyValidatorTests.cs Lines 133 to 141 in 83c34ce
|
ChildCanDependOnParentImplicitly="true" and
Will cause any references between the Core.Something.SubSomething namespace (and it's children) to Core.Something.SubSomething.* namespaces to throw an illegal namespace warning.
And also, Core.Something.SubSomething.Things1 namespace should be able to reference Core.Something.SubSomething.Thing2 namespace without issue. but a lateral reference is not allowed. and since Disallowed is stronger than Allowed, the lateral movement is reported as an illegal reference.
The text was updated successfully, but these errors were encountered: