-
-
Notifications
You must be signed in to change notification settings - Fork 42
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
implement except(...) clause to improve expressivity #209
Comments
What do you think about something like this?
We can add to What do you think @micheleorselli @fain182 ? At the moment I am working on something like this solution but there Is many code to edit but it seems to works fine. |
I think that the selection of the classes should be in the "that" clause...
I am not sure about the name |
For the selection of the class should be in
|
@fain182 but what do you think about adding a second parameter to
|
It's not too bad to read, but how would you call in the signature the second argument of the should ? |
In my mind, @fain182 ,
We can use a nullable argument, I know it's not the best solution but adding another layer like:
This solution could be more complicated at the moment. |
In my opinion will be great have a method such as I don't know if it is applicable to the current codebase, if yes, I prefer have different methods with the same name
|
Well, with the new feature added in the #220 I have solved all my issues updating my rule as follow:
So for me this issue can be closed. PS |
You can use a variable as an array to contain all those classes |
Sure, I could also grouping the namespaces in less rows, putting more in a row, but the question is not this. The real question is: So why do not always consider this class to be not external to your namespace? PS.
.. replacing all root classes with '' or eventually with '*' (wildchars) ? |
Maybe we could avoid always to check dependency on PHP built-in classes, using something like this: https://www.php.net/manual/en/reflectionclass.isinternal.php... |
Feature Request
Summary
We may need a new exception clause (not a php exception) to apply to Rule::allClasses() that at this time does not exists (I believe).
As earlier discussed (@micheleorselli)...
The text was updated successfully, but these errors were encountered: