These are chat archives for DotNetAnalyzers/StyleCopAnalyzers

10th
Nov 2015
Johan Larsson
@JohanLarsson
Nov 10 2015 00:02
so beautiful!
Johan Larsson
@JohanLarsson
Nov 10 2015 00:29
OCD fireworks! (CDO)
Johan Larsson
@JohanLarsson
Nov 10 2015 07:05
private new static void Equals(object x, object y)
{
    throw new NotSupportedException();
}
private static new void Equals(object x, object y)
{
    throw new NotSupportedException();
}
neither makes cop happy
Johan Larsson
@JohanLarsson
Nov 10 2015 07:18
wanted to hide equals in an assert class so it is not visible in case you are wondering why i write so strange code
Yaakov
@yaakov-h
Nov 10 2015 08:22
I dunno about the StyleCop side, but I don't think that code will do what you want it to
Johan Larsson
@JohanLarsson
Nov 10 2015 08:27
I want to hide (object).Equals(x, y) in intellisense
As the assert class has an Equal(expected, actual) method
Yaakov
@yaakov-h
Nov 10 2015 08:51
Try [EditorBrowsable] for that, though you'll likely still have the same issue with StyleCop.
Sam Harwell
@sharwell
Nov 10 2015 13:40
@JohanLarsson What version are you using? I didn't see any warnings reported for the second form.
Johan Larsson
@JohanLarsson
Nov 10 2015 13:40
Latest, installed yesterday, maybe it is R# that has an opinion about it
It worked really really well, nice work guys.
Sam Harwell
@sharwell
Nov 10 2015 14:28
:+1:
Johan Larsson
@JohanLarsson
Nov 10 2015 16:16
public IEnumerator<Child> GetEnumerator() => this.children.GetEnumerator();

IEnumerator IEnumerable.GetEnumerator() => this.GetEnumerator();
what do you think of expression bodies?
I think they are really nice and prefer them to curlies even if the lines gets long
They read 'nothing to see here' nicely imo
Sam Harwell
@sharwell
Nov 10 2015 19:56
I tend to use them for very short bodies
Johan Larsson
@JohanLarsson
Nov 10 2015 20:08
yeah, I have never used them for more than one line I think
@sharwell ^ have you ever seen anything more beautiful? (The alignment) :)
but you will start on the next line of course