selenium 3.12 changed the type of exception being thrown

--- src/FluentBrowserAutomation/Controls/Properties/ICanBeClicked.cs
+++ src/FluentBrowserAutomation/Controls/Properties/ICanBeClicked.cs
@@ -1,5 +1,4 @@
-using System;
-
+using OpenQA.Selenium;
 using OpenQA.Selenium.Remote;

 // ReSharper disable once CheckNamespace
@@ -39,10 +38,10 @@
 				webElement.Click();
 				return true;
 			}
-			catch (InvalidOperationException invalidOperationException)
+			catch (WebDriverException exception)
 			{
 				element.Focus();
-                if (invalidOperationException.Message.Contains("Other element would receive the click") || invalidOperationException.Message.Contains("Element is not clickable at point"))
+                if (exception.Message.Contains("Other element would receive the click") || exception.Message.Contains("Element is not clickable at point"))
 				{
 					// try scrolling down to the element
 					var yLocation = ((RemoteWebElement)webElement.RemoteWebElement).Location.Y + 100;
@@ -54,11 +53,11 @@
 							webElement.Click();
 							return true;
 						}
-						catch (InvalidOperationException invalidOperationException2)
+						catch (WebDriverException webDriverException)
 						{
-                            if (!invalidOperationException2.Message.Contains("Other element would receive the click") && !invalidOperationException.Message.Contains("Element is not clickable at point"))
+                            if (!webDriverException.Message.Contains("Other element would receive the click") && !exception.Message.Contains("Element is not clickable at point"))
 							{
-								throw new AssertionException(invalidOperationException);
+								throw new AssertionException(exception);
 							}
 						}
 					}


Removed unused constructor

Removed unused constructor

--- src/FluentMigrator.Runner.Core/Initialization/MigrationSource.cs
+++ src/FluentMigrator.Runner.Core/Initialization/MigrationSource.cs
@@ -25,6 +25,9 @@

 namespace FluentMigrator.Runner.Initialization
 {
+    /// <summary>
+    /// The default implementation of a <see cref="IFilteringMigrationSource"/>.
+    /// </summary>
     public class MigrationSource : IFilteringMigrationSource
     {
         [NotNull]
@@ -59,23 +62,6 @@
             _conventions = conventions;
             _serviceProvider = serviceProvider;
             _sourceItems = sourceItems;
-        }
-
-        /// <summary>
-        /// Initializes a new instance of the <see cref="ProfileSource"/> class.
-        /// </summary>
-        /// <param name="source">The assembly source</param>
-        /// <param name="conventions">The migration runner conventios</param>
-        /// <param name="serviceProvider">The service provider</param>
-        public MigrationSource(
-            [NotNull] IAssemblySource source,
-            [NotNull] IMigrationRunnerConventions conventions,
-            [NotNull] IServiceProvider serviceProvider)
-        {
-            _source = source;
-            _conventions = conventions;
-            _serviceProvider = serviceProvider;
-            _sourceItems = Enumerable.Empty<IMigrationSourceItem>();
         }

         /// <summary>


Resolves n2cms/n2cms#176 Non-page Content Items are written out to current working directory rather than the data directory

--- src/Framework/N2/Persistence/Serialization/Html/XmlRepository.cs
+++ src/Framework/N2/Persistence/Serialization/Html/XmlRepository.cs
@@ -121,7 +121,7 @@
 			// ReSharper disable LoopCanBeConvertedToQuery
 			var type = item.GetType();
 			foreach (var p in type.GetProperties().Where(p => p.Name.ToLower() == "id"))
-				return String.Format("{0}-{1}.xml", type.Name, p.GetValue(item, null));
+				return Path.Combine(DataDirectoryPhysical, String.Format("t{0}-{1}.xml", type.Name, p.GetValue(item, null)));
 			return null;
 			// ReSharper restore LoopCanBeConvertedToQuery
 		}


Update InteractiveHost.Service.cs

Update InteractiveHost.Service.cs

--- src/Interactive/Host/Interactive/Core/InteractiveHost.Service.cs
+++ src/Interactive/Host/Interactive/Core/InteractiveHost.Service.cs
@@ -44,7 +44,7 @@
             private readonly object _lastTaskGuard = new object();
             private Task<EvaluationState> _lastTask;

-            private static InteractiveHostPlatformInfo s_currentPlatformInfo = InteractiveHostPlatformInfo.GetCurrentPlatformInfo();
+            private static readonly InteractiveHostPlatformInfo s_currentPlatformInfo = InteractiveHostPlatformInfo.GetCurrentPlatformInfo();

             private sealed class ServiceState : IDisposable
             {


Follow up

Follow up

--- src/Kephas.Orchestration/Application/RootAppLifecycleBehavior.cs
+++ src/Kephas.Orchestration/Application/RootAppLifecycleBehavior.cs
@@ -99,6 +99,9 @@
         /// </returns>
         public override Task BeforeAppFinalizeAsync(IAppContext appContext, CancellationToken cancellationToken = default)
         {
+            this.restartSubscription?.Dispose();
+            this.restartSubscription = null;
+
             return this.StopWorkerProcessesAsync(appContext, cancellationToken);
         }


Fix for #15

Fix for #15

--- src/Libraries/SharpDox.Build.NRefactory/Loader/CSharpSolution.cs
+++ src/Libraries/SharpDox.Build.NRefactory/Loader/CSharpSolution.cs
@@ -95,6 +95,7 @@
                     var location = match.Groups["Location"].Value;
                     switch (typeGuid.ToUpperInvariant())
                     {
+                        case "{C3E8C798-5B6F-2EA9-3A09-100A2C098994}": // Unity Project
                         case "{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}": // C# project
                             var projectFile = Path.Combine(Directory, location);
                             if (File.Exists(projectFile))


BUG: Lucene.Net.Tests.Facet.Taxonomy.Directory.TestAddTaxonomy: create random temp file instead of file in current directory.

--- src/Lucene.Net.Tests.Facet/Taxonomy/Directory/TestAddTaxonomy.cs
+++ src/Lucene.Net.Tests.Facet/Taxonomy/Directory/TestAddTaxonomy.cs
@@ -112,7 +112,7 @@
         {
             if (Random().NextBoolean())
             {
-                return new DiskOrdinalMap("taxoMap");
+                return new DiskOrdinalMap(CreateTempFile("taxoMap", "").FullName);
             }
             else
             {


Remove Usage of RazorIrNodeVisitorOfT (#5991)

--- src/Microsoft.AspNetCore.Mvc.Razor.Host/InjectDirectiveIRNode.cs
+++ src/Microsoft.AspNetCore.Mvc.Razor.Host/InjectDirectiveIRNode.cs
@@ -31,16 +31,6 @@
             AcceptExtensionNode<InjectDirectiveIRNode>(this, visitor);
         }

-        public override TResult Accept<TResult>(RazorIRNodeVisitor<TResult> visitor)
-        {
-            if (visitor == null)
-            {
-                throw new ArgumentNullException(nameof(visitor));
-            }
-
-            return AcceptExtensionNode<InjectDirectiveIRNode, TResult>(this, visitor);
-        }
-
         public override void WriteNode(RuntimeTarget target, CSharpRenderingContext context)
         {
             if (target == null)


Change package layout structure + PDBs

Change package layout structure + PDBs

This changes the layout structure to match that of a NuGet layout.

I've also added a step to find and copy the PDBs.

--- src/Microsoft.DotNet.Build.Tasks.Packaging/src/GetLayoutFiles.cs
+++ src/Microsoft.DotNet.Build.Tasks.Packaging/src/GetLayoutFiles.cs
@@ -96,14 +96,16 @@
                         continue;
                     }

+                    var fxFolder = fx.GetShortFolderName();
+
                     if (rid == null)
                     {
                         // only consider compile assets for RID-less target
-                        layoutFiles.AddRange(CreateLayoutFiles(target.CompileAssets, "ref", fx, null, "Compile"));
+                        layoutFiles.AddRange(CreateLayoutFiles(target.CompileAssets, $"ref\\{fxFolder}", "Compile"));
                     }

-                    layoutFiles.AddRange(CreateLayoutFiles(target.RuntimeAssets, "runtime", fx, rid, "Runtime"));
-                    layoutFiles.AddRange(CreateLayoutFiles(target.NativeAssets, "runtime", fx, rid, "Native"));
+                    layoutFiles.AddRange(CreateLayoutFiles(target.RuntimeAssets, $"runtimes\\{rid}\\lib\\{fxFolder}", "Runtime"));
+                    layoutFiles.AddRange(CreateLayoutFiles(target.NativeAssets, $"runtimes\\{rid}\\native", "Native"));
                 }
             }

@@ -113,38 +115,39 @@
         }

-        private IEnumerable<ITaskItem> CreateLayoutFiles(IEnumerable<PackageAsset> assets, string subFolder, NuGetFramework framework, string rid, string assetType)
+        private IEnumerable<ITaskItem> CreateLayoutFiles(IEnumerable<PackageAsset> assets, string subFolder, string assetType)
         {
             return assets.Where(a => !NuGetAssetResolver.IsPlaceholder(a.LocalPath))
-                .Select(a => CreateLayoutFile(a.LocalPath, subFolder, framework, rid, assetType));
+                .SelectMany(a => CreateLayoutFile(a.LocalPath, subFolder, assetType));

         }

-        private ITaskItem CreateLayoutFile(string source, string subfolder, NuGetFramework framework,  string rid, string assetType)
+        static string[] s_symbolExtensions = { ".pdb", ".dwarf", ".dbg" };
+        private IEnumerable<ITaskItem> CreateLayoutFile(string source, string subfolder, string assetType)
         {
             var item = new TaskItem(source);
-
-            string fx = framework.GetShortFolderName();
-            var destination = Path.Combine(DestinationDirectory, subfolder, fx);
-
-            if (rid != null)
-            {
-                destination = Path.Combine(destination, rid);
-            }
-
-            destination = Path.Combine(destination, Path.GetFileName(source));
+            var destination = Path.Combine(DestinationDirectory, subfolder, Path.GetFileName(source));

             item.SetMetadata("Destination", destination);
-            item.SetMetadata("Framework", fx);
-
-            if (!String.IsNullOrEmpty(rid))
-            {
-                item.SetMetadata("RuntimeID", rid);
-            }
-
             item.SetMetadata("AssetType", assetType);

-            return item;
+            yield return item;
+
+            foreach(var symbolExtension in s_symbolExtensions)
+            {
+                var symbolSource = Path.ChangeExtension(source, symbolExtension);
+
+                if (File.Exists(symbolSource))
+                {
+                    var symbolItem = new TaskItem(symbolSource);
+                    var symbolDestination = Path.Combine(DestinationDirectory, subfolder, Path.GetFileName(symbolSource));
+
+                    symbolItem.SetMetadata("Destination", symbolDestination);
+                    symbolItem.SetMetadata("AssetType", assetType);
+
+                    yield return symbolItem;
+                }
+            }
         }
     }
 }


Normalized line-endings. Was mixed, mostly LF, so a few CR-LF was replaced with LF.

--- src/NLog/Internal/FileAppenders/MutexMultiProcessFileAppender.cs
+++ src/NLog/Internal/FileAppenders/MutexMultiProcessFileAppender.cs
@@ -37,7 +37,7 @@
 {
     using System;
     using System.Globalization;
-    using System.IO;
+    using System.IO;
     using System.Security;
     using System.Threading;
     using NLog.Common;
@@ -52,9 +52,9 @@
     /// pointer to the end of the file and appending can be made one operation.
     /// On Win32 we need to maintain some synchronization between processes
     /// (global named mutex is used for this)
-    /// </remarks>
-#if !NET2_0 && !NETCF2_0 && !NETCF3_5 && !SILVERLIGHT2
-    [SecuritySafeCritical]
+    /// </remarks>
+#if !NET2_0 && !NETCF2_0 && !NETCF3_5 && !SILVERLIGHT2
+    [SecuritySafeCritical]
 #endif
     internal class MutexMultiProcessFileAppender : BaseFileAppender
     {


Fixed minor formatting issues

Fixed minor formatting issues

--- src/NUnitFramework/framework/Internal/Results/TestSuiteResult.cs
+++ src/NUnitFramework/framework/Internal/Results/TestSuiteResult.cs
@@ -76,11 +76,11 @@
                 RwLock.EnterReadLock();
 #endif
                 try
-                    {
+                {
                     return _failCount;
-                    }
-                finally
-                    {
+                }
+                finally
+                {
 #if PARALLEL
                     RwLock.ExitReadLock();
 #endif
@@ -100,11 +100,11 @@
                 RwLock.EnterReadLock();
 #endif
                 try
-                    {
+                {
                     return _passCount;
-                    }
-                finally
-                    {
+                }
+                finally
+                {
 #if PARALLEL
                     RwLock.ExitReadLock();
 #endif
@@ -124,11 +124,11 @@
                 RwLock.EnterReadLock();
 #endif
                 try
-                    {
+                {
                     return _skipCount;
-                    }
-                finally
-                    {
+                }
+                finally
+                {
 #if PARALLEL
                     RwLock.ExitReadLock();
 #endif
@@ -216,6 +216,7 @@
             {
                 // If this result is marked cancelled, don't change it
                 if (ResultState != ResultState.Cancelled)
+                {
                     switch (result.ResultState.Status)
                     {
                         case TestStatus.Passed:
@@ -241,6 +242,7 @@

                             break;
                     }
+                }

                 InternalAssertCount += result.AssertCount;
                 _passCount += result.PassCount;


Fixed missing TODO

Fixed missing TODO

--- src/Umbraco.Web.Website/Extensions/HtmlHelperRenderExtensions.cs
+++ src/Umbraco.Web.Website/Extensions/HtmlHelperRenderExtensions.cs
@@ -4,6 +4,7 @@
 using System.Net;
 using System.Text;
 using System.Text.Encodings.Web;
+using System.Threading.Tasks;
 using System.Web;
 using Microsoft.AspNetCore.Antiforgery;
 using Microsoft.AspNetCore.DataProtection;
@@ -18,6 +19,7 @@
 using Umbraco.Cms.Core.Hosting;
 using Umbraco.Cms.Core.IO;
 using Umbraco.Cms.Core.Logging;
+using Umbraco.Cms.Core.Security;
 using Umbraco.Cms.Core.Web;
 using Umbraco.Cms.Core.Web.Mvc;
 using Umbraco.Cms.Web.Common.Controllers;
@@ -82,7 +84,7 @@

         }

-        public static IHtmlContent CachedPartial(
+        public static async Task<IHtmlContent> CachedPartialAsync(
             this IHtmlHelper htmlHelper,
             string partialViewName,
             object model,
@@ -113,11 +115,9 @@

             if (cacheByMember)
             {
-                // TODO reintroduce when members are migrated
-                throw new NotImplementedException("Reintroduce when members are migrated");
-                // var helper = Current.MembershipHelper;
-                // var currentMember = helper.GetCurrentMember();
-                // cacheKey.AppendFormat("m{0}-", currentMember?.Id ?? 0);
+                var memberManager = htmlHelper.ViewContext.HttpContext.RequestServices.GetRequiredService<IMemberManager>();
+                var currentMember = await memberManager.GetCurrentMemberAsync();
+                cacheKey.AppendFormat("m{0}-", currentMember?.Id ?? "0");
             }

             if (contextualKeyBuilder != null)


Use a folder icon for remote label

Use a folder icon for remote label

--- src/UnityExtension/Assets/Editor/GitHub.Unity/UI/BranchesView.cs
+++ src/UnityExtension/Assets/Editor/GitHub.Unity/UI/BranchesView.cs
@@ -144,7 +144,7 @@
                     for (var index = 0; index < remotes.Count; ++index)
                     {
                         var remote = remotes[index];
-                        GUILayout.Label(remote.Name);
+                        GUILayout.Label(new GUIContent(remote.Name, Styles.FolderIcon), GUILayout.MaxHeight(EditorGUIUtility.singleLineHeight));

                         // Branches of the remote
                         GUILayout.BeginHorizontal();


Construct submissions with empty file path in VS

Sets file paths for parsed syntax tree to "" in VS document state.
This is the same path name as set by the scripting API.

--- src/Workspaces/Core/Portable/Workspace/Solution/DocumentState.cs
+++ src/Workspaces/Core/Portable/Workspace/Solution/DocumentState.cs
@@ -87,10 +87,17 @@
         }

         // This is the string used to represent the FilePath property on a SyntaxTree object.
-        // if the document does not yet have a file path, use the document's name instead.
+        // if the document does not yet have a file path, use the document's name instead in regular code
+        // or an empty string in script code.
         private static string GetSyntaxTreeFilePath(DocumentInfo info)
         {
-            return info.FilePath ?? info.Name;
+            if (info.FilePath != null)
+            {
+                return info.FilePath;
+            }
+            return info.SourceCodeKind == SourceCodeKind.Regular
+                ? info.Name
+                : "";
         }

         private static ValueSource<TreeAndVersion> CreateLazyFullyParsedTree(


Fix OnComplete never happening in certain cases

--- osu.Framework/Graphics/Transforms/TransformSequence.cs
+++ osu.Framework/Graphics/Transforms/TransformSequence.cs
@@ -1,6 +1,7 @@
 // Copyright (c) 2007-2017 ppy Pty Ltd <contact@ppy.sh>.
 // Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu-framework/master/LICENCE

+using osu.Framework.MathUtils;
 using System;
 using System.Collections.Generic;
 using System.Diagnostics;
@@ -58,7 +59,7 @@
                 onLoopingTransform();

             // Update last transform for completion callback
-            if (transform.EndTime > endTime)
+            if (Precision.AlmostBigger(transform.EndTime, endTime))
             {
                 if (last != null)
                     last.OnComplete = null;
@@ -86,8 +87,15 @@
             using (origin.BeginDelayedSequence(currentTime - startTime))
                 child = childGenerator.Invoke(origin);

+            var oldLast = last;
             foreach (var t in child.transforms)
                 Append(t);
+
+            // If we flatten a child into ourselves that already completed, then
+            // we need to make sure to update the hasCompleted value, too, since
+            // the already completed final transform will no longer fire any events.
+            if (oldLast != last)
+                hasCompleted = child.hasCompleted;

             return this;
         }


Reset some variables

Reset some variables

--- osu.Framework/Graphics/Visualisation/DrawVisualiser.cs
+++ osu.Framework/Graphics/Visualisation/DrawVisualiser.cs
@@ -118,6 +118,9 @@
                 v.Dispose();

             visCache.Clear();
+
+            target = null;
+            targetVisualiser = null;
         }

         private Drawable findTargetIn(Drawable d, InputState state)


Reorder initialisation of bindable action binding to make more sense

--- osu.Game/Graphics/UserInterface/ShearedToggleButton.cs
+++ osu.Game/Graphics/UserInterface/ShearedToggleButton.cs
@@ -47,6 +47,7 @@

         protected override void LoadComplete()
         {
+            Active.BindDisabledChanged(disabled => Action = disabled ? (Action?)null : Active.Toggle, true);
             Active.BindValueChanged(_ =>
             {
                 updateActiveState();
@@ -54,9 +55,6 @@
             });

             updateActiveState();
-
-            Active.BindDisabledChanged(disabled => Action = disabled ? (Action?)null : Active.Toggle, true);
-
             base.LoadComplete();
         }


Fix nullref during room creation (#4228)

--- osu.Game/Screens/Multi/Match/Components/ReadyButton.cs
+++ osu.Game/Screens/Multi/Match/Components/ReadyButton.cs
@@ -55,6 +55,9 @@

         private void beatmapAdded(BeatmapSetInfo model, bool existing, bool silent)
         {
+            if (Beatmap.Value == null)
+                return;
+
             if (model.Beatmaps.Any(b => b.OnlineBeatmapID == Beatmap.Value.OnlineBeatmapID))
                 Schedule(() => hasBeatmap = true);
         }


C#: Refactor Tuples to use expression body syntax.

--- csharp/extractor/Semmle.Extraction.CSharp/Tuples.cs
+++ csharp/extractor/Semmle.Extraction.CSharp/Tuples.cs
@@ -17,723 +17,438 @@
     /// </remarks>
     internal static class Tuples
     {
-        internal static void assemblies(this System.IO.TextWriter trapFile, Assembly assembly, Extraction.Entities.File file, string identifier, string name, string version)
-        {
+        internal static void assemblies(this System.IO.TextWriter trapFile, Assembly assembly, Extraction.Entities.File file, string identifier, string name, string version) =>
             trapFile.WriteTuple("assemblies", assembly, file, identifier, name, version);
-        }
-
-        internal static void accessor_location(this TextWriter trapFile, Accessor accessorKey, Location location)
-        {
+
+        internal static void accessor_location(this TextWriter trapFile, Accessor accessorKey, Location location) =>
             trapFile.WriteTuple("accessor_location", accessorKey, location);
-        }
-
-        internal static void accessors(this TextWriter trapFile, Accessor accessorKey, int kind, string name, Property propKey, Accessor unboundAccessor)
-        {
+
+        internal static void accessors(this TextWriter trapFile, Accessor accessorKey, int kind, string name, Property propKey, Accessor unboundAccessor) =>
             trapFile.WriteTuple("accessors", accessorKey, kind, name, propKey, unboundAccessor);
-        }
-
-        internal static void init_only_accessors(this TextWriter trapFile, Accessor accessorKey)
-        {
+
+        internal static void init_only_accessors(this TextWriter trapFile, Accessor accessorKey) =>
             trapFile.WriteTuple("init_only_accessors", accessorKey);
-        }
-
-        internal static void array_element_type(this TextWriter trapFile, ArrayType array, int dimension, int rank, Type elementType)
-        {
+
+        internal static void array_element_type(this TextWriter trapFile, ArrayType array, int dimension, int rank, Type elementType) =>
             trapFile.WriteTuple("array_element_type", array, dimension, rank, elementType);
-        }
-
-        internal static void attributes(this TextWriter trapFile, Attribute attribute, Type attributeType, IEntity entity)
-        {
+
+        internal static void attributes(this TextWriter trapFile, Attribute attribute, Type attributeType, IEntity entity) =>
             trapFile.WriteTuple("attributes", attribute, attributeType, entity);
-        }
-
-        internal static void attribute_location(this TextWriter trapFile, Attribute attribute, Location location)
-        {
+
+        internal static void attribute_location(this TextWriter trapFile, Attribute attribute, Location location) =>
             trapFile.WriteTuple("attribute_location", attribute, location);
-        }
-
-        internal static void catch_type(this TextWriter trapFile, Entities.Statements.Catch @catch, Type type, bool explicityCaught)
-        {
+
+        internal static void catch_type(this TextWriter trapFile, Entities.Statements.Catch @catch, Type type, bool explicityCaught) =>
             trapFile.WriteTuple("catch_type", @catch, type, explicityCaught ? 1 : 2);
-        }
-
-        internal static void foreach_stmt_info(this TextWriter trapFile, Entities.Statements.ForEach @foreach, bool isAsync)
-        {
+
+        internal static void foreach_stmt_info(this TextWriter trapFile, Entities.Statements.ForEach @foreach, bool isAsync) =>
             trapFile.WriteTuple("foreach_stmt_info", @foreach, isAsync ? 2 : 1);
-        }

         internal static void foreach_stmt_desugar(this TextWriter trapFile, Entities.Statements.ForEach @foreach, IEntity entity,
-            Entities.Statements.ForEach.ForeachSymbolType type)
-        {
-            trapFile.WriteTuple("foreach_stmt_desugar", @foreach, entity, (int)type);
-        }
-
-        internal static void commentblock(this TextWriter trapFile, CommentBlock k)
-        {
+            Entities.Statements.ForEach.ForeachSymbolType type) => trapFile.WriteTuple("foreach_stmt_desugar", @foreach, entity, (int)type);
+
+        internal static void commentblock(this TextWriter trapFile, CommentBlock k) =>
             trapFile.WriteTuple("commentblock", k);
-        }
-
-        internal static void commentblock_binding(this TextWriter trapFile, CommentBlock commentBlock, Label entity, CommentBinding binding)
-        {
+
+        internal static void commentblock_binding(this TextWriter trapFile, CommentBlock commentBlock, Label entity, CommentBinding binding) =>
             trapFile.WriteTuple("commentblock_binding", commentBlock, entity, (int)binding);
-        }
-
-        internal static void commentblock_child(this TextWriter trapFile, CommentBlock commentBlock, CommentLine commentLine, int child)
-        {
+
+        internal static void commentblock_child(this TextWriter trapFile, CommentBlock commentBlock, CommentLine commentLine, int child) =>
             trapFile.WriteTuple("commentblock_child", commentBlock, commentLine, child);
-        }
-
-        internal static void commentblock_location(this TextWriter trapFile, CommentBlock k, Location l)
-        {
+
+        internal static void commentblock_location(this TextWriter trapFile, CommentBlock k, Location l) =>
             trapFile.WriteTuple("commentblock_location", k, l);
-        }
-
-        internal static void commentline(this TextWriter trapFile, CommentLine commentLine, CommentLineType type, string text, string rawtext)
-        {
+
+        internal static void commentline(this TextWriter trapFile, CommentLine commentLine, CommentLineType type, string text, string rawtext) =>
             trapFile.WriteTuple("commentline", commentLine, (int)type, text, rawtext);
-        }
-
-        internal static void commentline_location(this TextWriter trapFile, CommentLine commentLine, Location location)
-        {
+
+        internal static void commentline_location(this TextWriter trapFile, CommentLine commentLine, Location location) =>
             trapFile.WriteTuple("commentline_location", commentLine, location);
-        }
-
-        internal static void compilation_args(this TextWriter trapFile, Compilation compilation, int index, string arg)
-        {
+
+        internal static void compilation_args(this TextWriter trapFile, Compilation compilation, int index, string arg) =>
             trapFile.WriteTuple("compilation_args", compilation, index, arg);
-        }
-
-        internal static void compilation_compiling_files(this TextWriter trapFile, Compilation compilation, int index, Extraction.Entities.File file)
-        {
+
+        internal static void compilation_compiling_files(this TextWriter trapFile, Compilation compilation, int index, Extraction.Entities.File file) =>
             trapFile.WriteTuple("compilation_compiling_files", compilation, index, file);
-        }
-
-        internal static void compilation_referencing_files(this TextWriter trapFile, Compilation compilation, int index, Extraction.Entities.File file)
-        {
+
+        internal static void compilation_referencing_files(this TextWriter trapFile, Compilation compilation, int index, Extraction.Entities.File file) =>
             trapFile.WriteTuple("compilation_referencing_files", compilation, index, file);
-        }
-
-        internal static void compilation_finished(this TextWriter trapFile, Compilation compilation, float cpuSeconds, float elapsedSeconds)
-        {
+
+        internal static void compilation_finished(this TextWriter trapFile, Compilation compilation, float cpuSeconds, float elapsedSeconds) =>
             trapFile.WriteTuple("compilation_finished", compilation, cpuSeconds, elapsedSeconds);
-        }
-
-        internal static void compilation_time(this TextWriter trapFile, Compilation compilation, int num, int index, float metric)
-        {
+
+        internal static void compilation_time(this TextWriter trapFile, Compilation compilation, int num, int index, float metric) =>
             trapFile.WriteTuple("compilation_time", compilation, num, index, metric);
-        }
-
-        internal static void compilations(this TextWriter trapFile, Compilation compilation, string cwd)
-        {
+
+        internal static void compilations(this TextWriter trapFile, Compilation compilation, string cwd) =>
             trapFile.WriteTuple("compilations", compilation, cwd);
-        }
-
-        internal static void compilation_assembly(this TextWriter trapFile, Compilation compilation, Assembly assembly)
-        {
+
+        internal static void compilation_assembly(this TextWriter trapFile, Compilation compilation, Assembly assembly) =>
             trapFile.WriteTuple("compilation_assembly", compilation, assembly);
-        }
-
-        internal static void compiler_generated(this TextWriter trapFile, IEntity entity)
-        {
+
+        internal static void compiler_generated(this TextWriter trapFile, IEntity entity) =>
             trapFile.WriteTuple("compiler_generated", entity);
-        }
-
-        internal static void conditional_access(this TextWriter trapFile, Expression access)
-        {
+
+        internal static void conditional_access(this TextWriter trapFile, Expression access) =>
             trapFile.WriteTuple("conditional_access", access);
-        }
-
-        internal static void constant_value(this TextWriter trapFile, IEntity field, string value)
-        {
+
+        internal static void constant_value(this TextWriter trapFile, IEntity field, string value) =>
             trapFile.WriteTuple("constant_value", field, value);
-        }
-
-        internal static void constructed_generic(this TextWriter trapFile, IEntity constructedTypeOrMethod, IEntity unboundTypeOrMethod)
-        {
+
+        internal static void constructed_generic(this TextWriter trapFile, IEntity constructedTypeOrMethod, IEntity unboundTypeOrMethod) =>
             trapFile.WriteTuple("constructed_generic", constructedTypeOrMethod, unboundTypeOrMethod);
-        }
-
-        internal static void constructor_location(this TextWriter trapFile, Constructor constructor, Location location)
-        {
+
+        internal static void constructor_location(this TextWriter trapFile, Constructor constructor, Location location) =>
             trapFile.WriteTuple("constructor_location", constructor, location);
-        }
-
-        internal static void constructors(this TextWriter trapFile, Constructor key, string name, Type definingType, Constructor originalDefinition)
-        {
+
+        internal static void constructors(this TextWriter trapFile, Constructor key, string name, Type definingType, Constructor originalDefinition) =>
             trapFile.WriteTuple("constructors", key, name, definingType, originalDefinition);
-        }
-
-        internal static void delegate_return_type(this TextWriter trapFile, Type delegateKey, Type returnType)
-        {
+
+        internal static void delegate_return_type(this TextWriter trapFile, Type delegateKey, Type returnType) =>
             trapFile.WriteTuple("delegate_return_type", delegateKey, returnType);
-        }
-
-        internal static void function_pointer_return_type(this TextWriter trapFile, Type functionPointer, Type returnType)
-        {
+
+        internal static void function_pointer_return_type(this TextWriter trapFile, Type functionPointer, Type returnType) =>
             trapFile.WriteTuple("function_pointer_return_type", functionPointer, returnType);
-        }
-
-        internal static void destructor_location(this TextWriter trapFile, Destructor destructor, Location location)
-        {
+
+        internal static void destructor_location(this TextWriter trapFile, Destructor destructor, Location location) =>
             trapFile.WriteTuple("destructor_location", destructor, location);
-        }
-
-        internal static void destructors(this TextWriter trapFile, Destructor destructor, string name, Type containingType, Destructor original)
-        {
+
+        internal static void destructors(this TextWriter trapFile, Destructor destructor, string name, Type containingType, Destructor original) =>
             trapFile.WriteTuple("destructors", destructor, name, containingType, original);
-        }
-
-        internal static void diagnostic_for(this TextWriter trapFile, Diagnostic diag, Compilation comp, int fileNo, int index)
-        {
+
+        internal static void diagnostic_for(this TextWriter trapFile, Diagnostic diag, Compilation comp, int fileNo, int index) =>
             trapFile.WriteTuple("diagnostic_for", diag, comp, fileNo, index);
-        }
-
-        internal static void diagnostics(this TextWriter trapFile, Diagnostic diag, int severity, string errorTag, string errorMessage, string fullErrorMessage, Location location)
-        {
+
+        internal static void diagnostics(this TextWriter trapFile, Diagnostic diag, int severity, string errorTag, string errorMessage, string fullErrorMessage, Location location) =>
             trapFile.WriteTuple("diagnostics", diag, severity, errorTag, errorMessage, fullErrorMessage, location);
-        }
-
-        internal static void dynamic_member_name(this TextWriter trapFile, Expression e, string name)
-        {
+
+        internal static void dynamic_member_name(this TextWriter trapFile, Expression e, string name) =>
             trapFile.WriteTuple("dynamic_member_name", e, name);
-        }
-
-        internal static void enum_underlying_type(this TextWriter trapFile, Type @enum, Type type)
-        {
+
+        internal static void enum_underlying_type(this TextWriter trapFile, Type @enum, Type type) =>
             trapFile.WriteTuple("enum_underlying_type", @enum, type);
-        }
-
-        internal static void event_accessor_location(this TextWriter trapFile, EventAccessor accessor, Location location)
-        {
+
+        internal static void event_accessor_location(this TextWriter trapFile, EventAccessor accessor, Location location) =>
             trapFile.WriteTuple("event_accessor_location", accessor, location);
-        }
-
-        internal static void event_accessors(this TextWriter trapFile, EventAccessor accessorKey, int type, string name, Event eventKey, EventAccessor unboundAccessor)
-        {
+
+        internal static void event_accessors(this TextWriter trapFile, EventAccessor accessorKey, int type, string name, Event eventKey, EventAccessor unboundAccessor) =>
             trapFile.WriteTuple("event_accessors", accessorKey, type, name, eventKey, unboundAccessor);
-        }
-
-        internal static void event_location(this TextWriter trapFile, Event eventKey, Location locationKey)
-        {
+
+        internal static void event_location(this TextWriter trapFile, Event eventKey, Location locationKey) =>
             trapFile.WriteTuple("event_location", eventKey, locationKey);
-        }
-
-        internal static void events(this TextWriter trapFile, Event eventKey, string name, Type declaringType, Type memberType, Event originalDefinition)
-        {
+
+        internal static void events(this TextWriter trapFile, Event eventKey, string name, Type declaringType, Type memberType, Event originalDefinition) =>
             trapFile.WriteTuple("events", eventKey, name, declaringType, memberType, originalDefinition);
-        }
-
-        internal static void explicitly_implements(this TextWriter trapFile, IEntity member, Type @interface)
-        {
+
+        internal static void explicitly_implements(this TextWriter trapFile, IEntity member, Type @interface) =>
             trapFile.WriteTuple("explicitly_implements", member, @interface);
-        }
-
-        internal static void explicitly_sized_array_creation(this TextWriter trapFile, Expression array)
-        {
+
+        internal static void explicitly_sized_array_creation(this TextWriter trapFile, Expression array) =>
             trapFile.WriteTuple("explicitly_sized_array_creation", array);
-        }
-
-        internal static void expr_access(this TextWriter trapFile, Expression expr, IEntity access)
-        {
+
+        internal static void expr_access(this TextWriter trapFile, Expression expr, IEntity access) =>
             trapFile.WriteTuple("expr_access", expr, access);
-        }
-
-        internal static void expr_argument(this TextWriter trapFile, Expression expr, int mode)
-        {
+
+        internal static void expr_argument(this TextWriter trapFile, Expression expr, int mode) =>
             trapFile.WriteTuple("expr_argument", expr, mode);
-        }
-
-        internal static void expr_argument_name(this TextWriter trapFile, Expression expr, string name)
-        {
+
+        internal static void expr_argument_name(this TextWriter trapFile, Expression expr, string name) =>
             trapFile.WriteTuple("expr_argument_name", expr, name);
-        }
-
-        internal static void expr_call(this TextWriter trapFile, Expression expr, Method target)
-        {
+
+        internal static void expr_call(this TextWriter trapFile, Expression expr, Method target) =>
             trapFile.WriteTuple("expr_call", expr, target);
-        }
-
-        internal static void expr_compiler_generated(this TextWriter trapFile, Expression expr)
-        {
+
+        internal static void expr_compiler_generated(this TextWriter trapFile, Expression expr) =>
             trapFile.WriteTuple("expr_compiler_generated", expr);
-        }
-
-        internal static void expr_flowstate(this TextWriter trapFile, Expression expr, int flowState)
-        {
+
+        internal static void expr_flowstate(this TextWriter trapFile, Expression expr, int flowState) =>
             trapFile.WriteTuple("expr_flowstate", expr, flowState);
-        }
-
-        internal static void expr_location(this TextWriter trapFile, Expression expr, Location location)
-        {
+
+        internal static void expr_location(this TextWriter trapFile, Expression expr, Location location) =>
             trapFile.WriteTuple("expr_location", expr, location);
-        }
-
-        internal static void expr_parent(this TextWriter trapFile, Expression expr, int child, IExpressionParentEntity parent)
-        {
+
+        internal static void expr_parent(this TextWriter trapFile, Expression expr, int child, IExpressionParentEntity parent) =>
             trapFile.WriteTuple("expr_parent", expr, child, parent);
-        }
-
-        internal static void expr_parent_top_level(this TextWriter trapFile, Expression expr, int child, IExpressionParentEntity parent)
-        {
+
+        internal static void expr_parent_top_level(this TextWriter trapFile, Expression expr, int child, IExpressionParentEntity parent) =>
             trapFile.WriteTuple("expr_parent_top_level", expr, child, parent);
-        }
-
-        internal static void expr_value(this TextWriter trapFile, Expression expr, string value)
-        {
+
+        internal static void expr_value(this TextWriter trapFile, Expression expr, string value) =>
             trapFile.WriteTuple("expr_value", expr, value);
-        }
-
-        internal static void expressions(this TextWriter trapFile, Expression expr, ExprKind kind, Type exprType)
-        {
+
+        internal static void expressions(this TextWriter trapFile, Expression expr, ExprKind kind, Type exprType) =>
             trapFile.WriteTuple("expressions", expr, (int)kind, exprType);
-        }
-
-        internal static void exprorstmt_name(this TextWriter trapFile, IEntity expr, string name)
-        {
+
+        internal static void exprorstmt_name(this TextWriter trapFile, IEntity expr, string name) =>
             trapFile.WriteTuple("exprorstmt_name", expr, name);
-        }
-
-        internal static void extend(this TextWriter trapFile, Type type, Type super)
-        {
+
+        internal static void extend(this TextWriter trapFile, Type type, Type super) =>
             trapFile.WriteTuple("extend", type, super);
-        }
-
-        internal static void anonymous_types(this TextWriter trapFile, Type type)
-        {
+
+        internal static void anonymous_types(this TextWriter trapFile, Type type) =>
             trapFile.WriteTuple("anonymous_types", type);
-        }
-
-        internal static void field_location(this TextWriter trapFile, Field field, Location location)
-        {
+
+        internal static void field_location(this TextWriter trapFile, Field field, Location location) =>
             trapFile.WriteTuple("field_location", field, location);
-        }
-
-        internal static void fields(this TextWriter trapFile, Field field, int @const, string name, Type declaringType, Type fieldType, Field unboundKey)
-        {
+
+        internal static void fields(this TextWriter trapFile, Field field, int @const, string name, Type declaringType, Type fieldType, Field unboundKey) =>
             trapFile.WriteTuple("fields", field, @const, name, declaringType, fieldType, unboundKey);
-        }
-
-        internal static void general_type_parameter_constraints(this TextWriter trapFile, TypeParameterConstraints constraints, int hasKind)
-        {
+
+        internal static void general_type_parameter_constraints(this TextWriter trapFile, TypeParameterConstraints constraints, int hasKind) =>
             trapFile.WriteTuple("general_type_parameter_constraints", constraints, hasKind);
-        }
-
-        internal static void has_modifiers(this TextWriter trapFile, IEntity entity, Modifier modifier)
-        {
+
+        internal static void has_modifiers(this TextWriter trapFile, IEntity entity, Modifier modifier) =>
             trapFile.WriteTuple("has_modifiers", entity, modifier);
-        }
-
-        internal static void implement(this TextWriter trapFile, Type type, Type @interface)
-        {
+
+        internal static void implement(this TextWriter trapFile, Type type, Type @interface) =>
             trapFile.WriteTuple("implement", type, @interface);
-        }
-
-        internal static void implicitly_typed_array_creation(this TextWriter trapFile, Expression array)
-        {
+
+        internal static void implicitly_typed_array_creation(this TextWriter trapFile, Expression array) =>
             trapFile.WriteTuple("implicitly_typed_array_creation", array);
-        }
-
-        internal static void implicitly_typed_object_creation(this TextWriter trapFile, Expression expression)
-        {
+
+        internal static void implicitly_typed_object_creation(this TextWriter trapFile, Expression expression) =>
             trapFile.WriteTuple("implicitly_typed_object_creation", expression);
-        }
-
-        internal static void indexer_location(this TextWriter trapFile, Indexer indexer, Location location)
-        {
+
+        internal static void indexer_location(this TextWriter trapFile, Indexer indexer, Location location) =>
             trapFile.WriteTuple("indexer_location", indexer, location);
-        }
-
-        internal static void indexers(this TextWriter trapFile, Indexer propKey, string name, Type declaringType, Type memberType, Indexer unboundProperty)
-        {
+
+        internal static void indexers(this TextWriter trapFile, Indexer propKey, string name, Type declaringType, Type memberType, Indexer unboundProperty) =>
             trapFile.WriteTuple("indexers", propKey, name, declaringType, memberType, unboundProperty);
-        }
-
-        internal static void local_function_stmts(this TextWriter trapFile, Entities.Statements.LocalFunction fnStmt, LocalFunction fn)
-        {
+
+        internal static void local_function_stmts(this TextWriter trapFile, Entities.Statements.LocalFunction fnStmt, LocalFunction fn) =>
             trapFile.WriteTuple("local_function_stmts", fnStmt, fn);
-        }
-
-        internal static void local_functions(this TextWriter trapFile, LocalFunction fn, string name, Type returnType, LocalFunction unboundFn)
-        {
+
+        internal static void local_functions(this TextWriter trapFile, LocalFunction fn, string name, Type returnType, LocalFunction unboundFn) =>
             trapFile.WriteTuple("local_functions", fn, name, returnType, unboundFn);
-        }
-
-        internal static void localvar_location(this TextWriter trapFile, LocalVariable var, Location location)
-        {
+
+        internal static void localvar_location(this TextWriter trapFile, LocalVariable var, Location location) =>
             trapFile.WriteTuple("localvar_location", var, location);
-        }
-
-        internal static void localvars(this TextWriter trapFile, LocalVariable key, int @const, string name, int @var, Type type, Expression expr)
-        {
+
+        internal static void localvars(this TextWriter trapFile, LocalVariable key, int @const, string name, int @var, Type type, Expression expr) =>
             trapFile.WriteTuple("localvars", key, @const, name, @var, type, expr);
-        }
-
-        public static void metadata_handle(this TextWriter trapFile, IEntity entity, Location assembly, int handleValue)
-        {
+
+        public static void metadata_handle(this TextWriter trapFile, IEntity entity, Location assembly, int handleValue) =>
             trapFile.WriteTuple("metadata_handle", entity, assembly, handleValue);
-        }
-
-        internal static void method_location(this TextWriter trapFile, Method method, Location location)
-        {
+
+        internal static void method_location(this TextWriter trapFile, Method method, Location location) =>
             trapFile.WriteTuple("method_location", method, location);
-        }
-
-        internal static void methods(this TextWriter trapFile, Method method, string name, Type declType, Type retType, Method originalDefinition)
-        {
+
+        internal static void methods(this TextWriter trapFile, Method method, string name, Type declType, Type retType, Method originalDefinition) =>
             trapFile.WriteTuple("methods", method, name, declType, retType, originalDefinition);
-        }
-
-        internal static void modifiers(this TextWriter trapFile, Label entity, string modifier)
-        {
+
+        internal static void modifiers(this TextWriter trapFile, Label entity, string modifier) =>
             trapFile.WriteTuple("modifiers", entity, modifier);
-        }
-
-        internal static void mutator_invocation_mode(this TextWriter trapFile, Expression expr, int mode)
-        {
+
+        internal static void mutator_invocation_mode(this TextWriter trapFile, Expression expr, int mode) =>
             trapFile.WriteTuple("mutator_invocation_mode", expr, mode);
-        }
-
-        internal static void namespace_declaration_location(this TextWriter trapFile, NamespaceDeclaration decl, Location location)
-        {
+
+        internal static void namespace_declaration_location(this TextWriter trapFile, NamespaceDeclaration decl, Location location) =>
             trapFile.WriteTuple("namespace_declaration_location", decl, location);
-        }
-
-        internal static void namespace_declarations(this TextWriter trapFile, NamespaceDeclaration decl, Namespace ns)
-        {
+
+        internal static void namespace_declarations(this TextWriter trapFile, NamespaceDeclaration decl, Namespace ns) =>
             trapFile.WriteTuple("namespace_declarations", decl, ns);
-        }
-
-        internal static void namespaces(this TextWriter trapFile, Namespace ns, string name)
-        {
+
+        internal static void namespaces(this TextWriter trapFile, Namespace ns, string name) =>
             trapFile.WriteTuple("namespaces", ns, name);
-        }
-
-        internal static void nested_types(this TextWriter trapFile, Type typeKey, Type declaringTypeKey, Type unboundTypeKey)
-        {
+
+        internal static void nested_types(this TextWriter trapFile, Type typeKey, Type declaringTypeKey, Type unboundTypeKey) =>
             trapFile.WriteTuple("nested_types", typeKey, declaringTypeKey, unboundTypeKey);
-        }
-
-        internal static void nullable_underlying_type(this TextWriter trapFile, Type nullableType, Type underlyingType)
-        {
+
+        internal static void nullable_underlying_type(this TextWriter trapFile, Type nullableType, Type underlyingType) =>
             trapFile.WriteTuple("nullable_underlying_type", nullableType, underlyingType);
-        }
-
-        internal static void nullability(this TextWriter trapFile, NullabilityEntity nullability, int annotation)
-        {
+
+        internal static void nullability(this TextWriter trapFile, NullabilityEntity nullability, int annotation) =>
             trapFile.WriteTuple("nullability", nullability, annotation);
-        }
-
-        internal static void nullability_parent(this TextWriter trapFile, NullabilityEntity nullability, int index, NullabilityEntity parent)
-        {
+
+        internal static void nullability_parent(this TextWriter trapFile, NullabilityEntity nullability, int index, NullabilityEntity parent) =>
             trapFile.WriteTuple("nullability_parent", nullability, index, parent);
-        }
-
-        internal static void numlines(this TextWriter trapFile, IEntity label, LineCounts lineCounts)
-        {
+
+        internal static void numlines(this TextWriter trapFile, IEntity label, LineCounts lineCounts) =>
             trapFile.WriteTuple("numlines", label, lineCounts.Total, lineCounts.Code, lineCounts.Comment);
-        }
-
-        internal static void operator_location(this TextWriter trapFile, UserOperator @operator, Location location)
-        {
+
+        internal static void operator_location(this TextWriter trapFile, UserOperator @operator, Location location) =>
             trapFile.WriteTuple("operator_location", @operator, location);
-        }
-
-        internal static void operators(this TextWriter trapFile, UserOperator method, string methodName, string symbol, Type classKey, Type returnType, UserOperator originalDefinition)
-        {
+
+        internal static void operators(this TextWriter trapFile, UserOperator method, string methodName, string symbol, Type classKey, Type returnType, UserOperator originalDefinition) =>
             trapFile.WriteTuple("operators", method, methodName, symbol, classKey, returnType, originalDefinition);
-        }
-
-        internal static void overrides(this TextWriter trapFile, Method overriding, Method overridden)
-        {
+
+        internal static void overrides(this TextWriter trapFile, Method overriding, Method overridden) =>
             trapFile.WriteTuple("overrides", overriding, overridden);
-        }
-
-        internal static void param_location(this TextWriter trapFile, Parameter param, Location location)
-        {
+
+        internal static void param_location(this TextWriter trapFile, Parameter param, Location location) =>
             trapFile.WriteTuple("param_location", param, location);
-        }
-
-        internal static void @params(this TextWriter trapFile, Parameter param, string name, Type type, int child, Parameter.Kind mode, IEntity method, Parameter originalDefinition)
-        {
+
+        internal static void @params(this TextWriter trapFile, Parameter param, string name, Type type, int child, Parameter.Kind mode, IEntity method, Parameter originalDefinition) =>
             trapFile.WriteTuple("params", param, name, type, child, (int)mode, method, originalDefinition);
-        }
-
-        internal static void parent_namespace(this TextWriter trapFile, IEntity type, Namespace parent)
-        {
+
+        internal static void parent_namespace(this TextWriter trapFile, IEntity type, Namespace parent) =>
             trapFile.WriteTuple("parent_namespace", type, parent);
-        }
-
-        internal static void parent_namespace_declaration(this TextWriter trapFile, IEntity item, NamespaceDeclaration parent)
-        {
+
+        internal static void parent_namespace_declaration(this TextWriter trapFile, IEntity item, NamespaceDeclaration parent) =>
             trapFile.WriteTuple("parent_namespace_declaration", item, parent);
-        }
-
-        internal static void pointer_referent_type(this TextWriter trapFile, PointerType pointerType, Type referentType)
-        {
+
+        internal static void pointer_referent_type(this TextWriter trapFile, PointerType pointerType, Type referentType) =>
             trapFile.WriteTuple("pointer_referent_type", pointerType, referentType);
-        }
-
-        internal static void property_location(this TextWriter trapFile, Property property, Location location)
-        {
+
+        internal static void property_location(this TextWriter trapFile, Property property, Location location) =>
             trapFile.WriteTuple("property_location", property, location);
-        }
-
-        internal static void properties(this TextWriter trapFile, Property propKey, string name, Type declaringType, Type memberType, Property unboundProperty)
-        {
+
+        internal static void properties(this TextWriter trapFile, Property propKey, string name, Type declaringType, Type memberType, Property unboundProperty) =>
             trapFile.WriteTuple("properties", propKey, name, declaringType, memberType, unboundProperty);
-        }
-
-        internal static void statements(this TextWriter trapFile, Statement stmt, StmtKind kind)
-        {
+
+        internal static void statements(this TextWriter trapFile, Statement stmt, StmtKind kind) =>
             trapFile.WriteTuple("statements", stmt, (int)kind);
-        }
-
-        internal static void specific_type_parameter_constraints(this TextWriter trapFile, TypeParameterConstraints constraints, Type baseType)
-        {
+
+        internal static void specific_type_parameter_constraints(this TextWriter trapFile, TypeParameterConstraints constraints, Type baseType) =>
             trapFile.WriteTuple("specific_type_parameter_constraints", constraints, baseType);
-        }
-
-        internal static void specific_type_parameter_nullability(this TextWriter trapFile, TypeParameterConstraints constraints, Type baseType, NullabilityEntity nullability)
-        {
+
+        internal static void specific_type_parameter_nullability(this TextWriter trapFile, TypeParameterConstraints constraints, Type baseType, NullabilityEntity nullability) =>
             trapFile.WriteTuple("specific_type_parameter_nullability", constraints, baseType, nullability);
-        }
-
-        internal static void function_pointer_calling_conventions(this TextWriter trapFile, FunctionPointerType type, int kind)
-        {
+
+        internal static void function_pointer_calling_conventions(this TextWriter trapFile, FunctionPointerType type, int kind) =>
             trapFile.WriteTuple("function_pointer_calling_conventions", type, kind);
-        }
-
-        internal static void has_unmanaged_calling_conventions(this TextWriter trapFile, FunctionPointerType type, int index, Type convention)
-        {
+
+        internal static void has_unmanaged_calling_conventions(this TextWriter trapFile, FunctionPointerType type, int index, Type convention) =>
             trapFile.WriteTuple("has_unmanaged_calling_conventions", type, index, convention);
-        }
-
-        internal static void stackalloc_array_creation(this TextWriter trapFile, Expression array)
-        {
+
+        internal static void stackalloc_array_creation(this TextWriter trapFile, Expression array) =>
             trapFile.WriteTuple("stackalloc_array_creation", array);
-        }
-
-        internal static void stmt_location(this TextWriter trapFile, Statement stmt, Location location)
-        {
+
+        internal static void stmt_location(this TextWriter trapFile, Statement stmt, Location location) =>
             trapFile.WriteTuple("stmt_location", stmt, location);
-        }
-
-        internal static void stmt_parent(this TextWriter trapFile, Statement stmt, int child, IStatementParentEntity parent)
-        {
+
+        internal static void stmt_parent(this TextWriter trapFile, Statement stmt, int child, IStatementParentEntity parent) =>
             trapFile.WriteTuple("stmt_parent", stmt, child, parent);
-        }
-
-        internal static void stmt_parent_top_level(this TextWriter trapFile, Statement stmt, int child, IStatementParentEntity parent)
-        {
+
+        internal static void stmt_parent_top_level(this TextWriter trapFile, Statement stmt, int child, IStatementParentEntity parent) =>
             trapFile.WriteTuple("stmt_parent_top_level", stmt, child, parent);
-        }
-
-        internal static void tuple_element(this TextWriter trapFile, TupleType type, int index, Field field)
-        {
+
+        internal static void tuple_element(this TextWriter trapFile, TupleType type, int index, Field field) =>
             trapFile.WriteTuple("tuple_element", type, index, field);
-        }
-
-        internal static void tuple_underlying_type(this TextWriter trapFile, TupleType type, NamedType underlying)
-        {
+
+        internal static void tuple_underlying_type(this TextWriter trapFile, TupleType type, NamedType underlying) =>
             trapFile.WriteTuple("tuple_underlying_type", type, underlying);
-        }
-
-        internal static void type_annotation(this TextWriter trapFile, IEntity element, Kinds.TypeAnnotation annotation)
-        {
+
+        internal static void type_annotation(this TextWriter trapFile, IEntity element, Kinds.TypeAnnotation annotation) =>
             trapFile.WriteTuple("type_annotation", element, (int)annotation);
-        }
-
-        internal static void type_arguments(this TextWriter trapFile, Type arg, int n, IEntity typeOrMethod)
-        {
+
+        internal static void type_arguments(this TextWriter trapFile, Type arg, int n, IEntity typeOrMethod) =>
             trapFile.WriteTuple("type_arguments", arg, n, typeOrMethod);
-        }
-
-        internal static void type_location(this TextWriter trapFile, Type type, Location location)
-        {
+
+        internal static void type_location(this TextWriter trapFile, Type type, Location location) =>
             trapFile.WriteTuple("type_location", type, location);
-        }
-
-        internal static void type_mention(this TextWriter trapFile, TypeMention ta, Type type, IEntity parent)
-        {
+
+        internal static void type_mention(this TextWriter trapFile, TypeMention ta, Type type, IEntity parent) =>
             trapFile.WriteTuple("type_mention", ta, type, parent);
-        }
-
-        internal static void type_mention_location(this TextWriter trapFile, TypeMention ta, Location loc)
-        {
+
+        internal static void type_mention_location(this TextWriter trapFile, TypeMention ta, Location loc) =>
             trapFile.WriteTuple("type_mention_location", ta, loc);
-        }
-
-        internal static void type_nullability(this TextWriter trapFile, IEntity element, NullabilityEntity nullability)
-        {
+
+        internal static void type_nullability(this TextWriter trapFile, IEntity element, NullabilityEntity nullability) =>
             trapFile.WriteTuple("type_nullability", element, nullability);
-        }
-
-        internal static void type_parameter_constraints(this TextWriter trapFile, TypeParameterConstraints constraints, TypeParameter typeParam)
-        {
+
+        internal static void type_parameter_constraints(this TextWriter trapFile, TypeParameterConstraints constraints, TypeParameter typeParam) =>
             trapFile.WriteTuple("type_parameter_constraints", constraints, typeParam);
-        }
-
-        internal static void type_parameters(this TextWriter trapFile, TypeParameter param, int child, IEntity typeOrMethod)
-        {
+
+        internal static void type_parameters(this TextWriter trapFile, TypeParameter param, int child, IEntity typeOrMethod) =>
             trapFile.WriteTuple("type_parameters", param, child, typeOrMethod, (int)param.Variance);
-        }
-
-        internal static void typeref_type(this TextWriter trapFile, NamedTypeRef typeref, Type type)
-        {
+
+        internal static void typeref_type(this TextWriter trapFile, NamedTypeRef typeref, Type type) =>
             trapFile.WriteTuple("typeref_type", typeref, type);
-        }
-
-        internal static void typerefs(this TextWriter trapFile, NamedTypeRef type, string name)
-        {
+
+        internal static void typerefs(this TextWriter trapFile, NamedTypeRef type, string name) =>
             trapFile.WriteTuple("typerefs", type, name);
-        }
-
-        internal static void types(this TextWriter trapFile, Type type, TypeKind kind, string name)
-        {
+
+        internal static void types(this TextWriter trapFile, Type type, TypeKind kind, string name) =>
             trapFile.WriteTuple("types", type, (int)kind, name);
-        }
-
-        internal static void using_namespace_directives(this TextWriter trapFile, UsingDirective @using, Namespace ns)
-        {
+
+        internal static void using_namespace_directives(this TextWriter trapFile, UsingDirective @using, Namespace ns) =>
             trapFile.WriteTuple("using_namespace_directives", @using, ns);
-        }
-
-        internal static void using_directive_location(this TextWriter trapFile, UsingDirective @using, Location location)
-        {
+
+        internal static void using_directive_location(this TextWriter trapFile, UsingDirective @using, Location location) =>
             trapFile.WriteTuple("using_directive_location", @using, location);
-        }
-
-        internal static void using_static_directives(this TextWriter trapFile, UsingDirective @using, Type type)
-        {
+
+        internal static void using_static_directives(this TextWriter trapFile, UsingDirective @using, Type type) =>
             trapFile.WriteTuple("using_static_directives", @using, type);
-        }

         internal static void preprocessor_directive_location<TDirective>(this TextWriter trapFile,
             PreprocessorDirective<TDirective> directive, Location location)
-            where TDirective : DirectiveTriviaSyntax
-        {
+            where TDirective : DirectiveTriviaSyntax =>
             trapFile.WriteTuple("preprocessor_directive_location", directive, location);
-        }

         internal static void preprocessor_directive_compilation<TDirective>(this TextWriter trapFile,
             PreprocessorDirective<TDirective> directive, Compilation compilation)
-            where TDirective : DirectiveTriviaSyntax
-        {
+            where TDirective : DirectiveTriviaSyntax =>
             trapFile.WriteTuple("preprocessor_directive_compilation", directive, compilation);
-        }

         internal static void preprocessor_directive_active<TDirective>(this TextWriter trapFile,
             PreprocessorDirective<TDirective> directive, bool isActive)
-            where TDirective : DirectiveTriviaSyntax
-        {
+            where TDirective : DirectiveTriviaSyntax =>
             trapFile.WriteTuple("preprocessor_directive_active", directive, isActive ? 1 : 0);
-        }
-
-        internal static void pragma_warnings(this TextWriter trapFile, PragmaWarningDirective pragma, int kind)
-        {
+
+        internal static void pragma_warnings(this TextWriter trapFile, PragmaWarningDirective pragma, int kind) =>
             trapFile.WriteTuple("pragma_warnings", pragma, kind);
-        }
-
-        internal static void pragma_warning_error_codes(this TextWriter trapFile, PragmaWarningDirective pragma, string errorCode, int child)
-        {
+
+        internal static void pragma_warning_error_codes(this TextWriter trapFile, PragmaWarningDirective pragma, string errorCode, int child) =>
             trapFile.WriteTuple("pragma_warning_error_codes", pragma, errorCode, child);
-        }
-
-        internal static void pragma_checksums(this TextWriter trapFile, PragmaChecksumDirective pragma, Extraction.Entities.File file, string guid, string bytes)
-        {
+
+        internal static void pragma_checksums(this TextWriter trapFile, PragmaChecksumDirective pragma, Extraction.Entities.File file, string guid, string bytes) =>
             trapFile.WriteTuple("pragma_checksums", pragma, file, guid, bytes);
-        }
-
-        internal static void directive_defines(this TextWriter trapFile, DefineDirective directive, string name)
-        {
+
+        internal static void directive_defines(this TextWriter trapFile, DefineDirective directive, string name) =>
             trapFile.WriteTuple("directive_defines", directive, name);
-        }
-
-        internal static void directive_undefines(this TextWriter trapFile, UndefineDirective directive, string name)
-        {
+
+        internal static void directive_undefines(this TextWriter trapFile, UndefineDirective directive, string name) =>
             trapFile.WriteTuple("directive_undefines", directive, name);
-        }
-
-        internal static void directive_warnings(this TextWriter trapFile, WarningDirective directive, string message)
-        {
+
+        internal static void directive_warnings(this TextWriter trapFile, WarningDirective directive, string message) =>
             trapFile.WriteTuple("directive_warnings", directive, message);
-        }
-
-        internal static void directive_errors(this TextWriter trapFile, ErrorDirective directive, string message)
-        {
+
+        internal static void directive_errors(this TextWriter trapFile, ErrorDirective directive, string message) =>
             trapFile.WriteTuple("directive_errors", directive, message);
-        }
-
-        internal static void directive_nullables(this TextWriter trapFile, NullableDirective directive, int setting, int target)
-        {
+
+        internal static void directive_nullables(this TextWriter trapFile, NullableDirective directive, int setting, int target) =>
             trapFile.WriteTuple("directive_nullables", directive, setting, target);
-        }
-
-        internal static void directive_lines(this TextWriter trapFile, LineDirective directive, int kind)
-        {
+
+        internal static void directive_lines(this TextWriter trapFile, LineDirective directive, int kind) =>
             trapFile.WriteTuple("directive_lines", directive, kind);
-        }
-
-        internal static void directive_line_value(this TextWriter trapFile, LineDirective directive, int line)
-        {
+
+        internal static void directive_line_value(this TextWriter trapFile, LineDirective directive, int line) =>
             trapFile.WriteTuple("directive_line_value", directive, line);
-        }
-
-        internal static void directive_line_file(this TextWriter trapFile, LineDirective directive, Extraction.Entities.File file)
-        {
+
+        internal static void directive_line_file(this TextWriter trapFile, LineDirective directive, Extraction.Entities.File file) =>
             trapFile.WriteTuple("directive_line_file", directive, file);
-        }
-
-        internal static void directive_regions(this TextWriter trapFile, RegionDirective directive, string name)
-        {
+
+        internal static void directive_regions(this TextWriter trapFile, RegionDirective directive, string name) =>
             trapFile.WriteTuple("directive_regions", directive, name);
-        }
-
-        internal static void directive_endregions(this TextWriter trapFile, EndRegionDirective directive, RegionDirective start)
-        {
+
+        internal static void directive_endregions(this TextWriter trapFile, EndRegionDirective directive, RegionDirective start) =>
             trapFile.WriteTuple("directive_endregions", directive, start);
-        }
-
-        internal static void regions(this TextWriter trapFile, RegionDirective start, EndRegionDirective end)
-        {
+
+        internal static void regions(this TextWriter trapFile, RegionDirective start, EndRegionDirective end) =>
             trapFile.WriteTuple("regions", start, end);
-        }
-
-        internal static void directive_ifs(this TextWriter trapFile, IfDirective directive, bool branchTaken, bool conditionValue)
-        {
+
+        internal static void directive_ifs(this TextWriter trapFile, IfDirective directive, bool branchTaken, bool conditionValue) =>
             trapFile.WriteTuple("directive_ifs", directive, branchTaken ? 1 : 0, conditionValue ? 1 : 0);
-        }

         internal static void directive_elifs(this TextWriter trapFile, ElifDirective directive, bool branchTaken, bool conditionValue,
-            IfDirective start, int index)
-        {
+            IfDirective start, int index) =>
             trapFile.WriteTuple("directive_elifs", directive, branchTaken ? 1 : 0, conditionValue ? 1 : 0, start, index);
-        }

         internal static void directive_elses(this TextWriter trapFile, ElseDirective directive, bool branchTaken,
-            IfDirective start, int index)
-        {
+            IfDirective start, int index) =>
             trapFile.WriteTuple("directive_elses", directive, branchTaken ? 1 : 0, start, index);
-        }
-
-        internal static void directive_endifs(this TextWriter trapFile, EndIfDirective directive, IfDirective start)
-        {
+
+        internal static void directive_endifs(this TextWriter trapFile, EndIfDirective directive, IfDirective start) =>
             trapFile.WriteTuple("directive_endifs", directive, start);
-        }
-
-        internal static void directive_define_symbols(this TextWriter trapFile, DefineSymbol symb, string name)
-        {
+
+        internal static void directive_define_symbols(this TextWriter trapFile, DefineSymbol symb, string name) =>
             trapFile.WriteTuple("directive_define_symbols", symb, name);
-        }
-
-        internal static void locations_mapped(this System.IO.TextWriter trapFile, NonGeneratedSourceLocation l1, Location l2)
-        {
+
+        internal static void locations_mapped(this System.IO.TextWriter trapFile, NonGeneratedSourceLocation l1, Location l2) =>
             trapFile.WriteTuple("locations_mapped", l1, l2);
-        }
-
-        internal static void file_extraction_mode(this System.IO.TextWriter trapFile, Entities.File file, int mode)
-        {
+
+        internal static void file_extraction_mode(this System.IO.TextWriter trapFile, Entities.File file, int mode) =>
             trapFile.WriteTuple("file_extraction_mode", file, mode);
-        }
     }
 }


made main window check and set minimum size correctly (win), closes #1348

--- src/ui/windows/TogglDesktop/TogglDesktop/MainWindowController.cs
+++ src/ui/windows/TogglDesktop/TogglDesktop/MainWindowController.cs
@@ -221,12 +221,32 @@

         Utils.LoadWindowLocation(this, editForm);

+        setCorrectMinimumSize();
+
         aboutWindowController.initAndCheck();

         runScriptTimer = new Timer();
         runScriptTimer.Interval = 1000;
         runScriptTimer.Tick += runScriptTimer_Tick;
         runScriptTimer.Start();
+    }
+
+    private void setCorrectMinimumSize()
+    {
+        Size minSize;
+        if (contentPanel.Controls.Contains(loginViewController))
+        {
+            minSize = new Size(loginViewController.MinimumSize.Width, loginViewController.MinimumSize.Height + 40);
+        }
+        else
+        {
+            minSize = new Size(230, 86);
+        }
+        if(minSize != MinimumSize)
+        {
+            MinimumSize = minSize;
+            updateResizeHandleBackground();
+        }
     }

     void runScriptTimer_Tick(object sender, EventArgs e)
@@ -471,7 +491,7 @@
             contentPanel.Controls.Remove(timeEntryListViewController);
             contentPanel.Controls.Remove(timeEntryEditViewController);
             contentPanel.Controls.Add(loginViewController);
-            MinimumSize = new Size(loginViewController.MinimumSize.Width, loginViewController.MinimumSize.Height + 40);
+            setCorrectMinimumSize();
             loginViewController.SetAcceptButton(this);
             resizeHandle.BackColor = Color.FromArgb(69, 69, 69);
         }
@@ -512,7 +532,7 @@
             troubleBox.Visible = false;
             contentPanel.Location = defaultContentPosition;
             contentPanel.Controls.Remove(loginViewController);
-            MinimumSize = new Size(230, 86);
+            setCorrectMinimumSize();
             contentPanel.Controls.Add(timeEntryListViewController);
             timeEntryListViewController.SetAcceptButton(this);
             if (editForm.Visible)


Add TransformCommandWithExtraLine test

Add TransformCommandWithExtraLine test

--- test/Markdown.MAML.Test/Transformer/ParserAndTransformerTests.cs
+++ test/Markdown.MAML.Test/Transformer/ParserAndTransformerTests.cs
@@ -22,6 +22,22 @@
             MamlCommand mamlCommand = (new ModelTransformer()).NodeModelToMamlModel(doc).First();
             Assert.Equal(mamlCommand.Name, "Get-Foo");
             Assert.Equal(mamlCommand.Synopsis, "This is Synopsis");
+        }
+
+        [Fact]
+        public void TransformCommandWithExtraLine()
+        {
+            var parser = new MarkdownParser();
+            var doc = parser.ParseString(@"
+##Add-Member
+
+###SYNOPSIS
+Adds custom properties and methods to an instance of a Windows PowerShell object.
+
+");
+            MamlCommand mamlCommand = (new ModelTransformer()).NodeModelToMamlModel(doc).First();
+            Assert.Equal(mamlCommand.Name, "Add-Member");
+            Assert.Equal(mamlCommand.Synopsis, "Adds custom properties and methods to an instance of a Windows PowerShell object.");
         }

         [Fact]


Corrected the HasDefect method in CommentRules

--- project/dexter-cs/DexterCRC/Src/CheckerLogic/CommentRules.cs
+++ project/dexter-cs/DexterCRC/Src/CheckerLogic/CommentRules.cs
@@ -18,8 +18,8 @@
         public bool HasDefect(object value)
         {
             string statement = value.ToString();
-            return !statement.StartsWith("///", StringComparison.Ordinal)
-                    && !statement.Contains("<summary>");
+            return !(statement.Trim().StartsWith("///", StringComparison.Ordinal)
+                && statement.Contains("<summary>"));
         }

         public PreOccurence MakeDefect(AnalysisConfig config, Checker checker, CSharpSyntaxNode raw)


AdventureSample - refactor Variables

AdventureSample - refactor Variables

--- projects/AdventureSample/src/GWBas2CS/BasicVisitor.cs
+++ projects/AdventureSample/src/GWBas2CS/BasicVisitor.cs
@@ -222,12 +222,12 @@
             {
                 foreach (Variable v in this.strs.Values)
                 {
-                    yield return v.Field(this.generator);
+                    yield return v.Field();
                 }

                 foreach (Variable v in this.nums.Values)
                 {
-                    yield return v.Field(this.generator);
+                    yield return v.Field();
                 }
             }

@@ -236,12 +236,12 @@
                 List<SyntaxNode> statements = new List<SyntaxNode>();
                 foreach (Variable v in this.strs.Values)
                 {
-                    statements.Add(v.Init(this.generator));
+                    statements.Add(v.Init());
                 }

                 foreach (Variable v in this.nums.Values)
                 {
-                    statements.Add(v.Init(this.generator));
+                    statements.Add(v.Init());
                 }

                 return this.generator.MethodDeclaration("Init", accessibility: Accessibility.Private, statements: statements);
@@ -249,40 +249,54 @@

             public SyntaxNode Add(BasicType type, string name)
             {
+                if (type == BasicType.Str)
+                {
+                    return this.Add(this.strs, type, name);
+                }
+
+                return this.Add(this.nums, type, name);
+            }
+
+            private SyntaxNode Add(IDictionary<string, Variable> vars, BasicType type, string name)
+            {
                 Variable v;
-
-                if (type == BasicType.Str)
-                {
-                    if (!this.strs.TryGetValue(name, out v))
-                    {
-                        v = new Variable(type, name);
-                        this.strs.Add(name, v);
-                    }
-                }
-                else
-                {
-                    if (!this.nums.TryGetValue(name, out v))
-                    {
-                        v = new Variable(type, name);
-                        this.nums.Add(name, v);
-                    }
-                }
-
-                return v.Ref(this.generator);
+                if (!vars.TryGetValue(name, out v))
+                {
+                    v = new Variable(this.generator, type, name);
+                    vars.Add(name, v);
+                }
+
+                return v.Ref();
             }

             private sealed class Variable
             {
+                private readonly SyntaxGenerator generator;
                 private readonly BasicType type;
                 private readonly string name;

-                public Variable(BasicType type, string name)
-                {
+                public Variable(SyntaxGenerator generator, BasicType type, string name)
+                {
+                    this.generator = generator;
                     this.type = type;
                     this.name = name;
                 }

-                public string Name
+                private SyntaxNode Type
+                {
+                    get
+                    {
+                        SpecialType ty = SpecialType.System_Single;
+                        if (this.type == BasicType.Str)
+                        {
+                            ty = SpecialType.System_String;
+                        }
+
+                        return this.generator.TypeExpression(ty);
+                    }
+                }
+
+                private string Name
                 {
                     get
                     {
@@ -296,41 +310,33 @@
                     }
                 }

-                public SyntaxNode Ref(SyntaxGenerator generator)
-                {
-                    return generator.IdentifierName(this.Name);
-                }
-
-                public SyntaxNode Field(SyntaxGenerator generator)
-                {
-                    return generator.FieldDeclaration(this.Name, this.Type(generator), accessibility: Accessibility.Private);
-                }
-
-                public SyntaxNode Init(SyntaxGenerator generator)
-                {
-                    return generator.AssignmentStatement(this.Ref(generator), this.Default(generator));
-                }
-
-                private SyntaxNode Default(SyntaxGenerator generator)
-                {
-                    object lit = 0;
-                    if (this.type == BasicType.Str)
-                    {
-                        lit = string.Empty;
-                    }
-
-                    return generator.LiteralExpression(lit);
-                }
-
-                private SyntaxNode Type(SyntaxGenerator generator)
-                {
-                    SpecialType ty = SpecialType.System_Single;
-                    if (this.type == BasicType.Str)
-                    {
-                        ty = SpecialType.System_String;
-                    }
-
-                    return generator.TypeExpression(ty);
+                private SyntaxNode Default
+                {
+                    get
+                    {
+                        object lit = 0;
+                        if (this.type == BasicType.Str)
+                        {
+                            lit = string.Empty;
+                        }
+
+                        return this.generator.LiteralExpression(lit);
+                    }
+                }
+
+                public SyntaxNode Ref()
+                {
+                    return this.generator.IdentifierName(this.Name);
+                }
+
+                public SyntaxNode Field()
+                {
+                    return this.generator.FieldDeclaration(this.Name, this.Type, accessibility: Accessibility.Private);
+                }
+
+                public SyntaxNode Init()
+                {
+                    return this.generator.AssignmentStatement(this.Ref(), this.Default);
                 }
             }
         }


Fix device section to make it work in application settings dialog.

--- Settings/DeviceSection.cs
+++ Settings/DeviceSection.cs
@@ -318,8 +318,8 @@
 				{
 					TableLayout.HorizontalScaled(15, m_lb_curdev, m_curdev),
 					new StackLayoutItem(m_tc, true),
-					TableLayout.HorizontalScaled(15, m_lb_newdev, m_newdev),
-					TableLayout.HorizontalScaled(15, m_reset, m_select),
+					m_for_app ? null : TableLayout.HorizontalScaled(15, m_lb_newdev, m_newdev),
+					m_for_app ? null : TableLayout.HorizontalScaled(15, m_reset, m_select),
 				}
 			};
 			Content = layout;
@@ -388,7 +388,7 @@
 				{
 					if (page is GridDevicePage p && p != sender) p.ClearSelection();
 				}
-				var vud = Plugin.GetActiveViewportSettings();
+				var vud = Settings; // Plugin.GetActiveViewportSettings();

 				m_newDevice = ccl.Device.DeviceFromString(senderpage.DeviceSelectionString());
 				if(vud!=null) vud.SelectedDeviceStr = m_newDevice.DeviceString;


(TFS CS 3625)

(TFS CS 3625)

--- Signum.Web/TypeContext.cs
+++ Signum.Web/TypeContext.cs
@@ -128,6 +128,7 @@
         {
             if (helper.WriteIdAndRuntime())
             {
+                //string prefix = (tc.Name != Signum.Web.TypeContext.Separator) ? tc.Name : "";
                 if (typeof(IdentifiableEntity).IsAssignableFrom(typeof(T)))
                 {
                     IdentifiableEntity id = (IdentifiableEntity)(object)tc.Value;
@@ -136,17 +137,32 @@
                         helper.ViewContext.HttpContext.Response.Write(
                             helper.Hidden(helper.GlobalPrefixedName(Signum.Web.TypeContext.Separator + Signum.Web.TypeContext.RuntimeType), typeof(T).Name) + "\n");
                     else
+                    {
+                        helper.ViewContext.HttpContext.Response.Write(
+                            helper.Hidden(helper.GlobalPrefixedName(Signum.Web.TypeContext.Separator + Signum.Web.TypeContext.RuntimeType), "") + "\n");
                         helper.ViewContext.HttpContext.Response.Write(
                             helper.Hidden(helper.GlobalPrefixedName(Signum.Web.TypeContext.Separator + Signum.Web.TypeContext.StaticType), typeof(T).Name) + "\n");
+                    }

                     helper.ViewContext.HttpContext.Response.Write(
                         helper.Hidden(helper.GlobalPrefixedName(Signum.Web.TypeContext.Separator + Signum.Web.TypeContext.Id), id.TryCS(i => i.IdOrNull)) + "\n");
+                    //if (tc.Value != null)
+                    //    helper.ViewContext.HttpContext.Response.Write(
+                    //        helper.Hidden(helper.GlobalName(Signum.Web.TypeContext.Compose(prefix, Signum.Web.TypeContext.RuntimeType)), typeof(T).Name) + "\n");
+                    //else
+                    //    helper.ViewContext.HttpContext.Response.Write(
+                    //        helper.Hidden(helper.GlobalName(Signum.Web.TypeContext.Compose(prefix, Signum.Web.TypeContext.StaticType)), typeof(T).Name) + "\n");
+
+                    //helper.ViewContext.HttpContext.Response.Write(
+                    //    helper.Hidden(helper.GlobalName(Signum.Web.TypeContext.Compose(prefix, Signum.Web.TypeContext.Id)), id.TryCS(i => i.IdOrNull)) + "\n");

                 }
                 else if (typeof(EmbeddedEntity).IsAssignableFrom(typeof(T)))
                 {
                     helper.ViewContext.HttpContext.Response.Write(
-                            helper.Hidden(helper.GlobalPrefixedName(Signum.Web.TypeContext.Separator + Signum.Web.TypeContext.RuntimeType), typeof(T).Name) + "\n");
+                        helper.Hidden(helper.GlobalPrefixedName(Signum.Web.TypeContext.Separator + Signum.Web.TypeContext.RuntimeType), typeof(T).Name) + "\n");
+                    //helper.ViewContext.HttpContext.Response.Write(
+                    //    helper.Hidden(helper.GlobalName(Signum.Web.TypeContext.Compose(prefix, Signum.Web.TypeContext.RuntimeType)), typeof(T).Name) + "\n");
                 }
             }
             //Avoid subcontexts to write their id and runtime, only the main embedded typecontext must write them
@@ -156,7 +172,9 @@

         public static TypeContext<S> TypeContext<T, S>(this HtmlHelper helper, TypeContext<T> parent, Expression<Func<T, S>> property)
         {
-            return Common.WalkExpression(parent, property);
+            TypeSubContext<S> typeContext = (TypeSubContext<S>)Common.WalkExpression(parent, property);
+            //helper.WriteRuntimeAndId(typeContext);
+            return typeContext;
         }
     }
     #endregion
@@ -236,7 +254,7 @@
         {
             get
             {
-                return prefix.HasText() ? prefix : TypeContext.Separator; //TypeContext.Separator + prefix;
+                return prefix.HasText() ? prefix : ""; //TypeContext.Separator;
             }
         }

@@ -315,7 +333,8 @@
             get
             {
                 string propertiesName = properties.ToString(p => p.Name, TypeContext.Separator);
-                return ((Parent.Name == TypeContext.Separator) ? "" : Parent.Name) +
+                return //((Parent.Name == TypeContext.Separator) ? "" : Parent.Name) +
+                    Parent.Name +
                     (propertiesName.HasText() ? TypeContext.Separator + propertiesName : "");
             }
         }
@@ -380,7 +399,7 @@
         {
             get
             {
-                return ""; // Parent.Name == TypeContext.Separator ? "" : Parent.Name;
+                return "";
             }
         }


update response statuscode to 302 after return from  auth provider

--- SimpleWAWS/Global.asax.cs
+++ SimpleWAWS/Global.asax.cs
@@ -142,7 +142,8 @@
                 var a = context.Request["state"];
                 var redirectlocation = a.Split('/')[0];
                 context.Response.RedirectLocation = redirectlocation;
-            }
+                context.Response.StatusCode = 302; // Redirect
+                }

             //if (context.Request.Cookies[Constants.TiPCookie] == null &&
             //    context.Request.QueryString[Constants.TiPCookie] != null)


code clean up

code clean up

--- SqlRuntimeCacheManager.cs
+++ SqlRuntimeCacheManager.cs
@@ -12,24 +12,10 @@
 {
     public sealed class SqlRuntimeCacheManager
     {
-        //private static string dbName = "CachedDatabase";
         private static string ConnectionString;
         private static DataContext DataContext;
         private static SqlRuntimeCacheManager _Instance;

-        //public static DataBaseEntity dbEntity
-        //{
-        //    get
-        //    {
-        //        var ctx = DataContextFactory.GetScopedDataContext<DataBaseEntity>(dbName);
-        //        if (ctx.Context == null)
-        //        {
-        //            ctx.Context = DataContext;
-        //        }
-
-        //        return ctx;
-        //    }
-        //}
         public static SqlRuntimeCacheManager Instance
         {
             get
@@ -63,12 +49,10 @@
         public List<T> GetAllCached<T>()
             where T : class, IDataEntity
         {
-            //var tableName = dbEntity.GetTableName<T>();
             var tableName = DataContext.GetTableName<T>();

             List<T> result = null;
             result = (List<T>)MemoryCache.Default.Get(tableName);
-

             if (result == null)
             {
@@ -84,7 +68,6 @@
                         SqlDependency dep = new SqlDependency();
                         dep.AddCommandDependency(cmd);

-                        //MemoryCache.Default.Set(table, value, policy);
                         var policy = new CacheItemPolicy()
                         {
                             AbsoluteExpiration = ObjectCache.InfiniteAbsoluteExpiration,


Matrix using BaseValuesNode

Matrix using BaseValuesNode

--- Src/TensorSharp/Matrix.cs
+++ Src/TensorSharp/Matrix.cs
@@ -19,6 +19,13 @@

         private static int[] CalculateShape(T[][] values)
         {
+            if (values == null)
+                throw new InvalidOperationException();
+
+            for (int k = 1; k < values.Length; k++)
+                if (values[k].Length != values[0].Length)
+                    throw new InvalidOperationException();
+
             int[] shape = new int[2];

             shape[0] = values.Length;
@@ -30,8 +37,16 @@
         private static T[] ToFlatArray(T[][] values)
         {
             int[] shape = CalculateShape(values);
+            int nrows = shape[0];
+            int ncols = shape[1];

-            T[] flatvalues = new T[shape[0] * shape[1]];
+            T[] flatvalues = new T[nrows * ncols];
+
+            int k = 0;
+
+            for (int x = 0; x < ncols; x++)
+                for (int y = 0; y < nrows; y++)
+                    flatvalues[k++] = values[y][x];

             return flatvalues;
         }


Probably fix lost connection crash

Probably fix lost connection crash

--- StardewValleyMP/Server.cs
+++ StardewValleyMP/Server.cs
@@ -231,8 +231,16 @@

             ~Client()
             {
-                socket.disconnect();
-                receiver.Join();
+                if (socket != null)
+                {
+                    socket.disconnect();
+                    socket = null;
+                }
+                if (receiver != null)
+                {
+                    receiver.Join();
+                    receiver = null;
+                }
             }

             //public bool tempStopUpdating = false;


Show separator while dead

Show separator while dead

--- Unity/Assets/Gameplay.cs
+++ Unity/Assets/Gameplay.cs
@@ -61,6 +61,9 @@
 		if (currentTime <= 0.0f)
 		{
 			currentTime = 0.0f;
+			UpdateTimeRenderers();
+			separatorRenderer.enabled = true;
+
 			alarmSource.Stop();
 			alarmFX.SetActive(false);
 			neigeFX.SetActive(false);
@@ -79,9 +82,9 @@

 			float ratio = 1.0f - currentTime / initialTime;
 			backgroundMaterial.SetFloat(backgroundRatioAttributeName, ratio);
+
+			UpdateTimeRenderers();
 		}
-
-		UpdateTimeRenderers();
 	}

 	void UpdateTimeRenderers()


Fix typo

Fix typo

--- Store.Pgsql/src/Client.cs
+++ Store.Pgsql/src/Client.cs
@@ -62,7 +62,7 @@
         T o = merge(destRec.current, src);
         (o as Model).ts = DateTime.Now;

-        // Current is not merged
+        // Current is now merged
         destRec.current = o;
         destRec.ts = DateTime.Now;
         // Deque record into history


new sets of model state utils for api and mvc

--- Utils/ModelStateUtils.cs
+++ Utils/ModelStateUtils.cs
@@ -1,11 +1,21 @@
 using System.Collections.Generic;
 using System.Linq;
-using System.Web.Mvc;

 namespace MoarUtils.Utils {
   public class ModelStateUtils {
-    public static List<string> GetErrorListFromModelState(
-      ModelStateDictionary modelState
+    public static List<string> GetErrorListFromModelStateMvc(
+      System.Web.Mvc.ModelStateDictionary modelState
+    ) {
+      var query = from state in modelState.Values
+                  from error in state.Errors
+                  select error.ErrorMessage;
+
+      var errorList = query.ToList();
+      return errorList;
+    }
+
+    public static List<string> GetErrorListFromModelStateWebApi(
+      System.Web.Http.ModelBinding.ModelStateDictionary modelState
     ) {
       var query = from state in modelState.Values
                   from error in state.Errors


Extract methods

Extract methods

--- TPPCamComponent/TPPCam.cs
+++ TPPCamComponent/TPPCam.cs
@@ -225,7 +225,8 @@
             CalculateLerpSpeed();
             UpdateTargetTransformPosition();
             CheckTargetTransformOcclusion();
-            UpdateLookAtPointOffset();
+            HandleTargetTransformVisible();
+            HandleTargetTransformNotVisible();
             UpdateSmoothCamOffset();
             CalculateEndRotation();

@@ -260,6 +261,8 @@
         }

         private void UpdateSmoothCamOffset() {
+            UpdatedCameraOffset += TargetVelocity;
+
             // control occlusion offsets
             SmoothCamOffset = Vector3.MoveTowards(
                 SmoothCamOffset,
@@ -267,25 +270,27 @@
                 Time.fixedDeltaTime * PerspectiveChangeSpeed);
         }

-        // todo replace with two separate handlers
-        private void UpdateLookAtPointOffset() {
-            if (TargetTransformVisible) {
-                UpdatedCameraOffset = CameraOffset;
-                UpdatedLookAtPointOffset =
-                new Vector3(
-                    LookAtPointOffset.x,
-                    -SmoothCamOffset.y,
-                    LookAtPointOffset.y);
-            }
-            else {
-                UpdatedCameraOffset = OffsetWhenNotVisible;
-                UpdatedLookAtPointOffset = new Vector3(
-                    LookAtPointWhenNotVisible.x,
-                    -SmoothCamOffset.y,
-                    LookAtPointWhenNotVisible.z);
-            }
-
-            UpdatedCameraOffset += TargetVelocity;
+        private void HandleTargetTransformVisible() {
+            if (!TargetTransformVisible) return;
+
+            UpdatedCameraOffset = CameraOffset;
+
+            UpdatedLookAtPointOffset =
+            new Vector3(
+                LookAtPointOffset.x,
+                -SmoothCamOffset.y,
+                LookAtPointOffset.y);
+        }
+
+        private void HandleTargetTransformNotVisible() {
+            if (TargetTransformVisible) return;
+
+            UpdatedCameraOffset = OffsetWhenNotVisible;
+
+            UpdatedLookAtPointOffset = new Vector3(
+                LookAtPointWhenNotVisible.x,
+                -SmoothCamOffset.y,
+                LookAtPointWhenNotVisible.z);
         }

         private void CalculateLerpSpeed() {


Add ShouldSetBranchId and ShouldCreateBranchIfBranchIdIsSet tests

--- Source/Sitecore.FakeDb.Tests/Data/BranchRecordsTest.cs
+++ Source/Sitecore.FakeDb.Tests/Data/BranchRecordsTest.cs
@@ -6,8 +6,44 @@

   public class BranchRecordsTest
   {
+    private readonly ID branchId = ID.NewID;
+
     [Fact]
-    public void ShouldSetItemBranchIfExists()
+    public void ShouldSetBranchId()
+    {
+      // arrange
+      using (var db = new Db
+                        {
+                          new DbItem("home") { BranchId = this.branchId }
+                        })
+      {
+        // act
+        var item = db.GetItem("/sitecore/content/home");
+
+        // assert
+        item.BranchId.Should().Be(this.branchId);
+      }
+    }
+
+    [Fact(Skip = "To be implemented.")]
+    public void ShouldCreateBranchIfBranchIdIsSet()
+    {
+      // act
+      using (var db = new Db
+                        {
+                          new DbItem("home") { BranchId = this.branchId }
+                        })
+      {
+        var branch = db.Database.Branches[this.branchId];
+
+        // assert
+        branch.Should().NotBeNull();
+        branch.Name.Should().Be("home");
+      }
+    }
+
+    [Fact]
+    public void ShouldResolveAndSetBranchIdIfExists()
     {
       // arrange
       var branchItemId = ID.NewID;
@@ -30,18 +66,15 @@
     [Fact]
     public void ShouldReadDatabaseBranches()
     {
-      // arrange
-      var branchItemId = ID.NewID;
-
       // act
       using (var db = new Db
                         {
-                          new DbItem("Sample Branch", branchItemId, TemplateIDs.BranchTemplate),
+                          new DbItem("Sample Branch", this.branchId, TemplateIDs.BranchTemplate),
                         })
       {
         // assert
         db.Database.Branches["/sitecore/templates/branches/Sample Branch"].Should().NotBeNull();
-        db.Database.Branches[branchItemId].Should().NotBeNull();
+        db.Database.Branches[this.branchId].Should().NotBeNull();
       }
     }

@@ -49,18 +82,16 @@
     public void ShouldCreateItemFromBranch()
     {
       // arrange
-      var branchId = ID.NewID;
-
       using (var db = new Db { new DbItem("home") })
       {
         var item = db.GetItem("/sitecore/content/home");

         // act
-        var child = item.Add("child", new BranchId(branchId));
+        var child = item.Add("child", new BranchId(this.branchId));

         // assert
-        child.BranchId.Should().Be(branchId);
-        child.TemplateID.Should().NotBe(branchId);
+        child.BranchId.Should().Be(this.branchId);
+        child.TemplateID.Should().NotBe(this.branchId);
       }
     }
   }


Remove useless library pepxml

Remove useless library pepxml

--- TaskLayer/PepXMLWriter.cs
+++ TaskLayer/PepXMLWriter.cs
@@ -1,13 +1,9 @@
-using Chemistry;
-using EngineLayer;
-using MzLibUtil;
+using EngineLayer;
 using Proteomics;
 using System;
 using System.Collections.Generic;
 using System.IO;
 using System.Linq;
-using System.Text;
-using System.Xml;
 using System.Xml.Serialization;

 namespace TaskLayer


Update AddEducation.cshtml

Update AddEducation.cshtml

--- Source/Web/CvSystem.Web/Views/Home/AddEducation.cshtml
+++ Source/Web/CvSystem.Web/Views/Home/AddEducation.cshtml
@@ -74,6 +74,7 @@

             <input type="submit" value="Add Education" class="btn btn-success" />
+            @Html.ActionLink("Skip", "Index", "Home", null, new { @class = "btn btn-primary" })


Minor fix in Collision.TimeOfImpact.cs !Does not compile!

--- SourceFiles/Box2DX/Collision/Collision.TimeOfImpact.cs
+++ SourceFiles/Box2DX/Collision/Collision.TimeOfImpact.cs
@@ -311,7 +311,7 @@
                 {
                     // Use a mix of the secant rule and bisection.
                     float x;
-                    if (rootIterCount & 1)
+                    if ((rootIterCount & 1) != 0)
                     {
                         // Secant rule to improve convergence.
                         x = x1 + (target - f1) * (x2 - x1) / (f2 - f1);


Steam_Language

--- SteamTrade/SteamWeb.cs
+++ SteamTrade/SteamWeb.cs
@@ -380,6 +380,7 @@
                 _cookies.Add(new Cookie("sessionid", SessionId, string.Empty, SteamCommunityDomain));
                 _cookies.Add(new Cookie("steamLogin", Token, string.Empty, SteamCommunityDomain));
                 _cookies.Add(new Cookie("steamLoginSecure", TokenSecure, string.Empty, SteamCommunityDomain));
+                _cookies.Add(new Cookie("Steam_Language", "english", string.Empty, SteamCommunityDomain));

                 return true;
             }