Skip to content

Instantly share code, notes, and snippets.

View ycherkes's full-sized avatar
🇺🇦
#armukraineasap 🇳🇴

Yevhen Cherkes ycherkes

🇺🇦
#armukraineasap 🇳🇴
View GitHub Profile
@frankbryce
frankbryce / TypeSyntaxFactory.cs
Last active January 28, 2024 06:25
This is a factory to create a TypeSyntax Roslyn Model object from simple strings. Enjoy!
using System.Linq;
using Microsoft.CodeAnalysis.CSharp;
using Microsoft.CodeAnalysis.CSharp.Syntax;
namespace StackOverflow.Roslyn
{
public static class TypeSyntaxFactory
{
/// <summary>
/// Used to generate a type without generic arguments
@jvshahid
jvshahid / terminate.cs
Last active February 18, 2024 02:23
C# terminating a child process (as opposed to killing, i.e. sigkill vs. sigint on linux)
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Linq;
using System.Runtime.InteropServices;
using System.Text;
using System.Threading;
using System.Threading.Tasks;
namespace TestCtrlEvent