Daniel Grunwald
a2580063dd
Fix ExpressionOfCompatibleTypeCastIssue.
12 years ago
Daniel Grunwald
e85128df57
Fix unit test failure due to mix of tabs and spaces.
12 years ago
Ciprian Khlud
82c272545a
Fixed spacing
12 years ago
Ciprian Khlud
8666d6ffae
Fix of bug #11855
...
https://bugzilla.xamarin.com/show_bug.cgi?id=11855
This will notify user to use after ifs, whiles and fors not colons, but blocks.
12 years ago
Mike Krüger
ba13e28750
Fixed bug in redundant assignment issue.
12 years ago
Mike Krüger
05c5931a05
Disabled convert to static method issue.
...
It's not clear to me how the body analyzation is working - it seems to
be missing at all. Therefore I disable this issue until it's
implemented.
12 years ago
Mike Krüger
f40346db06
Fixed some issues in convert to static method issue.
12 years ago
Mike Krüger
fa671aacff
Fixed duplicate if chain issue tests.
12 years ago
Mike Krüger
5f867c5321
Ignore duplicate body method issue.
...
I take that one out for now - tests are failing and that's a very
unlikely issue to happen.
12 years ago
Mike Krüger
78442bb33a
Fixed static constructor access modifier issue tests.
12 years ago
Ciprian Khlud
c43a3ee9c3
Remove duplicate ifs, in if/else chains in case that the expression is duplicated. It can happen in copy/paste cases.
...
Fixes formatting of the previous commit to match K&R style.
12 years ago
Ciprian Khlud
6e4f648b48
Added code issue to address bug #11856
...
https://bugzilla.xamarin.com/show_bug.cgi?id=11856
This works for expressions by doing the following:
- it looks if the expression is the first in a sequence of conditional expressions
- if is first, it extracts all expressions in the chained expressions
- after that it compares all expressions and if two are found as duplicates, the first duplicate is shown
The code fix will remove the duplicate expression.
This bug will also look to bit operations ( & and | ) as they have similar semantics
12 years ago
Ciprian Khlud
bd486b50b0
Code updates
12 years ago
Ciprian Khlud
9db3f46cbc
Support non void arguments
12 years ago
Ciprian Khlud
ad0c12d1da
Sample implementation for bug #11866
...
https://bugzilla.xamarin.com/show_bug.cgi?id=11866
The test fails because EOLN issues for now, and it works just for methods that return void for now. But it does look for methods inside the classes that have same: arguments, return type and modifiers (so are duplicates)
12 years ago
Ciprian Khlud
eca73de6e4
ExpressionOfCompatibleTypeCodeIssue will not convert class types any longer.
13 years ago
Ciprian Khlud
17b26e4ce0
Added more unit tests to:
...
https://bugzilla.xamarin.com/show_bug.cgi?id=10728
There is a bug in conversion between double and float (in Convert part of the base classes)
13 years ago
Ciprian Khlud
0d391896fb
Fixes bug #10731
...
https://bugzilla.xamarin.com/show_bug.cgi?id=10731
It will look as a separate issue checker for basic interfaces and it will give the first implementation that works as base (so it will not give 5 possible conversions, even all are possible). In practice works really well. It is losely based on the ParameterCanbeDemotedIssue so I exposed the code to not duplicate it. Yet the code is much simpler this action.
13 years ago
Ciprian Khlud
dd8caea759
Fixes bug 11709 part of Xamarin's bugzilla: https://bugzilla.xamarin.com/show_bug.cgi?id=11709
...
It makes ConvertToStaticMethod as an issue.
13 years ago
Mike Krüger
62aaf41af6
Fixed failing built.
13 years ago
leoowen19
73f679e6c3
[CodeIssue] Modified PublicConstructorInAbstractClass issue to support Resharper disable comment
13 years ago
ciplogic
d1196a8ffb
Fixes bug #10728 (Auto-Fix regarding control flow: "Convert to correct type")
13 years ago
leoowen19
579d2aca48
[CodeIssue]PublicConstructorInAbstractClass
...
Convert modifiers of constructors in Abstract class from "public" to
"protected".
13 years ago
leoowen19
42921dca18
[CodeIssue] Redundant Constructor issue
...
Do not need an empty constructor
13 years ago
leoowen19
0d99a1c634
Two new code issues
...
1. Static contructor cannot take parameters.
2. Static constructor cannot take access modifier.
13 years ago
ciplogic
e5f2c0bfd6
Add the capability to remove base call if is not needed. It exposes some classes so maybe I'm not using the proper APIs. But it works good for practical the test case I wrote.
13 years ago
ciplogic
f806f635be
Auto-Fix for remove redundant assignment have issues in some cases (Part II) fixes
13 years ago
Mike Krüger
74ea8505b8
Added fix from Ciprian Khlud<ciprian.mustiata@yahoo.com>: Fix in
...
hoping to address the issues regarding some edge cases of remove
redundant variables in relation with functions.
13 years ago
Mike Krüger
ebe7045d05
Added some tests to the redundant null check.
13 years ago
Mike Krüger
01d4361350
Reformatted redundant null check.
13 years ago
leoowen19
ee3c6e89ed
[CodeIssue] Redundant Null Check
...
No need to check null where is keyword exits.
13 years ago
Mike Krüger
1d5c85f3f1
Implemented resharper disableing for redundant using directive.
13 years ago
Mike Krüger
020128ba58
CanBeDemotedIssue now respects the
...
CA1011:ConsiderPassingBaseTypesAsParameters suppression.
13 years ago
Mike Krüger
538f016c46
Implemented code issue message suppression.
13 years ago
Mike Krüger
1b99cfc3e8
Implemented new line ast node insertion.
13 years ago
Daniel Grunwald
ee5d87a0f8
Add year to license headers.
13 years ago
Mike Krüger
8be2eeef65
Fixed some false positives in parameter not used issue.
13 years ago
Mike Krüger
0c6e840997
Fixed unit test.
13 years ago
mkrueger
3b46fef92b
Fixed bug in redundant field initializer issue.
13 years ago
Mike Krüger
69d4fd1ff1
RedundantAssignment issue is now more careful when removing
...
invocations.
13 years ago
Mike Krüger
f700607114
SimplifyAnonymousMethodToDelegateIssues now doesn't touch too complex
...
expressions.
13 years ago
Daniel Grunwald
d267602fec
Fix crash when 'return 1;' occurs within a constructor declaration.
13 years ago
Mike Krüger
dc10a67ce7
[CodeIssues] Fixed naming issue.
13 years ago
Mike Krüger
d47e38efe7
[CodeIssues] Fixed bug in CS0127 issue.
13 years ago
Mike Krüger
40a2b81b43
Implemented issue provider for CS0127: A method with a void return
...
type cannot return a value.
This issue provider got requested - and I need to start somewhere to
implement semantic error issue providers.
13 years ago
Mike Krüger
f480c60aec
Added new code issue to simplify anonymous methods to delegate usages.
13 years ago
Mike Krüger
551869bd41
VariableDeclaredInWideScopeIssue no longer suggests moving method call
...
initializers.
13 years ago
Mike Krüger
24c588b70c
CheckFix is now more verbose.
13 years ago
Daniel Grunwald
3d96f7c7ff
Add fix action to ExplicitConversionInForEachIssue.
13 years ago
Daniel Grunwald
67d80c8834
CompareFloatWithEqualityOperatorIssue: don't show warning when comparing with infinities.
13 years ago