Comments (3)
The implementation of this rule is a little different from the original StyleCop version when it comes to the sections of a "for" loop. In the previous version, you would be nudged towards writing an "infinite" for loop as:
for (;;)
{
}
Other variants would trigger a violation of SA1002. By contrast, the only way to adhere to the rule now appears to be:
for (; ;)
{
}
which raised a violation of SA1002 in the previous version. Is this deliberate? The same difference is apparent if you add just an initializer to the loop.
I'm posting several queries of this style as I migrate an existing solution to use the StyleCop Analyzers; is it generally intended that the rules that existed in the previous version should preserve their behaviour?
from stylecopanalyzers.
@jackwhelpton It's normal for replies to "get lost" when they are added to issues that are already closed. You should open a new issue for items like this to make sure at a minimum that they get documented.
📝 Your comment is indirectly related to #633.
from stylecopanalyzers.
Raised #1489: cheers.
from stylecopanalyzers.
Related Issues (20)
- SAAllow primary constructor parameters to start with underscore.
- SA1313 Allow primary constructor parameters to start with underscore. HOT 1
- Inquiry about Adding Chinese Language Support to StyleCop.Analyzers
- SA1303: Can we configure this to warn if the 1st char is _ HOT 6
- SA1010 interferes with IDE0055 when = is followed by an array initialization HOT 4
- Make SA1201 configurable HOT 2
- Flags enums should be sorted HOT 1
- SA1013 fires for escaped closing brace in a multi-line interpolated verbatim string HOT 1
- conflict SA1024 and SA1009 HOT 1
- stylecop.analyzers is missing NuGet package README file
- `SA1629` code fix eats ending semicolon of XML entity
- `SA1402` Should not apply to file-scoped types HOT 1
- Missing period SA1629 should not trigger inside <example> tags. HOT 2
- `SA1629` should ignore `<example>` since a trailing period is often not valid input. HOT 2
- Rules contradicting C# naming conventions HOT 3
- SA1629 demands period for Value text HOT 2
- SA1202 fires for dependent members HOT 3
- SA1217 reporting incorrect order if System.* is placed alphabetically HOT 3
- [FP] When ``documentInternalElements`` is ``false`` in stylecop.json and it sees ``internal interface`` type. HOT 5
- SA1118 triggers for collection expression when List constructors worked just fine HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from stylecopanalyzers.