/csharp-query-insanity.cs Secret
Created
February 9, 2019 20:15
Star
You must be signed in to star a gist
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
using System.Text; | |
namespace CSharpExamples | |
{ | |
struct Point | |
{ | |
public int X { get { return 0; } } | |
public int Y { get { return 0; } } | |
} | |
class Foo | |
{ | |
public IEnumerable<Point> Select<T>(Func<string, T> selector) | |
{ | |
return new Point[0]; | |
} | |
} | |
static class Program | |
{ | |
static void Main(string[] args) | |
{ | |
var c = new Foo(); | |
var q = from X in c let Y = "" select Y.CompareTo(-1); | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment