$/
docs/
src/
tests/
samples/
artifacts/
packages/
build/
lib/
This file contains hidden or 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
public class NinjectFactory : IFactory | |
{ | |
private readonly IKernel kernel; | |
public Factory(IKernel kernel) | |
{ | |
this.kernel = kernel; | |
} | |
public T Get<T>() |
This file contains hidden or 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
// Make this C# code compile with minimal additional code (no commenting, etc.): Foo(0)(1)("two")("three")(4)(5)("six")("seven")(8)(9)("ten!"); | |
// https://twitter.com/dpoeschl/status/275464052216573952 | |
// How much more code to enforce the argument type pattern (i.e. int, int, string string, int, int, string, string...)? | |
// https://twitter.com/dpoeschl/status/275477464183103488 | |
// https://twitter.com/dpoeschl/status/275478110290444288 | |
// https://twitter.com/brianfriesen/status/275479513490669568 | |
delegate WhatTheFunc<T2,T3,T4,T1> WhatTheFunc<T1,T2,T3,T4>(T1 _); | |
void CreateFoo() |
This file contains hidden or 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
////////////////////////////////////////////////////////////////////////////////////// | |
// // | |
// This file was generated by a tool. It would be a bad idea to make changes to it. // | |
// // | |
////////////////////////////////////////////////////////////////////////////////////// | |
using System; | |
using System.Collections.Concurrent; | |
using System.Collections.Generic; | |
using System.IO; |
This file contains hidden or 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
#region | |
public interface IRegexNode | |
{ | |
ParseResult Parse(string input, int index); | |
} | |
public class ParseResult | |
{ | |
public bool Success; |
This file contains hidden or 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
<Query Kind="Program"> | |
<NuGetReference>Microsoft.Bcl.Immutable</NuGetReference> | |
<NuGetReference>NUnit</NuGetReference> | |
<Namespace>NUnit.Framework</Namespace> | |
<Namespace>System.Collections.Concurrent</Namespace> | |
<Namespace>System.Collections.Immutable</Namespace> | |
<Namespace>System.Threading.Tasks</Namespace> | |
</Query> | |
#define NONEST |
This file contains hidden or 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
void Main() | |
{ | |
int barInt; | |
object barObj = Foo.GetBar(); | |
barInt = (int)barObj; // Success! | |
dynamic barDynamic = Foo.GetBar(); | |
barInt = (int)barDynamic; // RuntimeBinderException: Cannot convert type 'System.Enum' to 'int' | |
} |
This file contains hidden or 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
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// | |
// Each member with an <inheritdoc/> tag does not render the <typeparamref> tag in its documentation tooltip correctly. | |
// Other documentation tags (<paramref/> and <c></c>) are included to demonstrate that other tags are rendered correctly. | |
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// | |
public static class GenericStaticClass<TArgument> | |
{ | |
/// <summary> | |
/// Summary:<br/>typeparamref: <typeparamref name="TArgument"/>.<br/>paramref: <paramref name="argument"/>.<br/><c>in-line code</c> | |
/// </summary> |