Browsing 7239 questions and answers with Jon Skeet
The problem is that you're definitely creating a BinaryOperator<Foo> - you have to be, as you're returning a Foo. If you change combined() to be declared to return Bar (while still accepting Foo) then you'd be fine. It's the fact... more 5/14/2016 4:16:08 PM
All the .NET Core source code is on Github, broken into corefx for the BCL beyond the bits that the CLR really depends on and coreclr for the CLR and the core parts of the BCL (like string). stringnative.cpp is the native part of the... more 5/14/2016 12:57:34 PM
Your attempt at replacing failed because you were using a C# string literal where \x is a C# escape sequence. You could have used something like: json = json.Replace("\\x22", "\\\""); ... which would replace \x22 with \" in the... more 5/14/2016 8:57:53 AM
I suspect the problem is that you're specifying null as the value for @pro. From the docs for AddWithValue: Use DBNull.Value instead of null, to indicate a null value. However, I would also suggest avoiding using AddWithValue to... more 5/14/2016 8:52:08 AM
You'll see this if the code in the try block can't throw any checked exception. At that point, the compiler knows that the only kind of exception caught by the catch block has to be an unchecked exception, and so it can therefore be... more 5/12/2016 11:44:30 AM
This condition checks for a key with a value "one": variations_array.Contains("one") That doesn't exist - you've added a single entry with a key of "hi". That's why your first Console.WriteLine doesn't execute. Next: string sv = (... more 5/12/2016 9:43:41 AM
You're calling getClass() on a java.lang.reflect.Type - so that's just going to give you Class.class... Effectively, you've called this.getClass().getClass(), and you don't want to do that. I suspect you want to change your validateId... more 5/12/2016 6:25:10 AM
From the docs: Each parameter of this function uses the default time zone unless a time zone is specified in that parameter. So my guess is that you're in a time zone where 2016-05-11 00:00:00 local is 2016-05-10 22:00:00 UTC. The... more 5/11/2016 7:54:49 AM
There's nothing special about default methods here. Java has always allowed interface methods to be declared public, even though they're already implicitly public. From JLS 9.4: Every method declaration in the body of an interface is... more 5/11/2016 6:30:45 AM
You're using different calls - you're calling writeObject in the writing part, then assuming that you can just read 4 bytes at a time in the reading part. Why not just use: Float[] floats = (Float[]) objectIn.readObject(); ? That would... more 5/10/2016 7:08:29 PM