diff --git a/.editorconfig b/.editorconfig index fdc2cb2e..837c2dc4 100644 --- a/.editorconfig +++ b/.editorconfig @@ -2,7 +2,7 @@ root = true [*] charset = utf-8 -insert_final_newline = false +insert_final_newline = true end_of_line = crlf [*.{yml,json}] @@ -12,6 +12,7 @@ indent_size = 2 [*.cs] indent_style = tab indent_size = 3 +tab_width = 3 # https://github.com/dotnet/roslyn/issues/22601 trim_trailing_whitespace = true dotnet_sort_system_directives_first = false @@ -55,6 +56,7 @@ csharp_new_line_before_members_in_object_initializers = true csharp_new_line_before_members_in_anonymous_types = true csharp_new_line_within_query_expression_clauses = true csharp_indent_case_contents = true +csharp_indent_case_contents_when_block = false csharp_indent_switch_labels = true csharp_indent_labels = no_change csharp_space_after_cast = false diff --git a/.gitignore b/.gitignore index c20f42e6..84b8305d 100644 --- a/.gitignore +++ b/.gitignore @@ -201,4 +201,4 @@ ModelManifest.xml /Harmony/Documentation/api/.manifest /Harmony/Documentation/api/*.html /Harmony/Documentation/api/*.yml -/Harmony/Documentation/Documentation.dll \ No newline at end of file +/Harmony/Documentation/Documentation.dll diff --git a/CNAME b/CNAME index 79055102..a471bb7f 100644 --- a/CNAME +++ b/CNAME @@ -1 +1 @@ -harmony.pardeike.net \ No newline at end of file +harmony.pardeike.net diff --git a/Harmony/Documentation/Documentation.csproj b/Harmony/Documentation/Documentation.csproj index bd76c8ea..8c098cbe 100644 --- a/Harmony/Documentation/Documentation.csproj +++ b/Harmony/Documentation/Documentation.csproj @@ -35,4 +35,4 @@ - \ No newline at end of file + diff --git a/Harmony/Documentation/examples/annotations_basic.cs b/Harmony/Documentation/examples/annotations_basic.cs index 98d4eae9..7e1b37d9 100644 --- a/Harmony/Documentation/examples/annotations_basic.cs +++ b/Harmony/Documentation/examples/annotations_basic.cs @@ -15,4 +15,4 @@ static void Postfix(/*...*/) // class SomeTypeHere { } -} \ No newline at end of file +} diff --git a/Harmony/Documentation/examples/annotations_combining.cs b/Harmony/Documentation/examples/annotations_combining.cs index d75f538d..5384ba89 100644 --- a/Harmony/Documentation/examples/annotations_combining.cs +++ b/Harmony/Documentation/examples/annotations_combining.cs @@ -48,4 +48,4 @@ class SomeType { } class TypeA { } class TypeB { } class TypeC { } -} \ No newline at end of file +} diff --git a/Harmony/Documentation/examples/annotations_multiple.cs b/Harmony/Documentation/examples/annotations_multiple.cs index f9f20b81..47f3cdb4 100644 --- a/Harmony/Documentation/examples/annotations_multiple.cs +++ b/Harmony/Documentation/examples/annotations_multiple.cs @@ -30,4 +30,4 @@ static void Prefix(MethodBase __originalMethod) class MyCode { } public static Assembly someAssembly; } -} \ No newline at end of file +} diff --git a/Harmony/Documentation/examples/basics.cs b/Harmony/Documentation/examples/basics.cs index 06f48a03..0341b73b 100644 --- a/Harmony/Documentation/examples/basics.cs +++ b/Harmony/Documentation/examples/basics.cs @@ -147,4 +147,4 @@ class MyPatchClass2 { } public static MethodInfo transpiler; } -} \ No newline at end of file +} diff --git a/Harmony/Documentation/examples/execution_with.cs b/Harmony/Documentation/examples/execution_with.cs index fa54b6bd..46083ea3 100644 --- a/Harmony/Documentation/examples/execution_with.cs +++ b/Harmony/Documentation/examples/execution_with.cs @@ -78,4 +78,4 @@ public class R { public R(string s) { } } public class T { } public static bool allVoid; } -} \ No newline at end of file +} diff --git a/Harmony/Documentation/examples/execution_without.cs b/Harmony/Documentation/examples/execution_without.cs index 729b93a8..51cb3108 100644 --- a/Harmony/Documentation/examples/execution_without.cs +++ b/Harmony/Documentation/examples/execution_without.cs @@ -56,4 +56,4 @@ static void Postfix1(ref R r) { } static R Postfix2(R r, params object[] arguments) { return r; } static void Postfix3() { } } -} \ No newline at end of file +} diff --git a/Harmony/Documentation/examples/intro_annotations.cs b/Harmony/Documentation/examples/intro_annotations.cs index 5dc0613c..fea4aec8 100644 --- a/Harmony/Documentation/examples/intro_annotations.cs +++ b/Harmony/Documentation/examples/intro_annotations.cs @@ -42,4 +42,4 @@ static void Postfix(ref int __result) } } // -} \ No newline at end of file +} diff --git a/Harmony/Documentation/examples/intro_manual.cs b/Harmony/Documentation/examples/intro_manual.cs index af19925d..d7835573 100644 --- a/Harmony/Documentation/examples/intro_manual.cs +++ b/Harmony/Documentation/examples/intro_manual.cs @@ -37,4 +37,4 @@ public static void MyPostfix() } } // -} \ No newline at end of file +} diff --git a/Harmony/Documentation/examples/intro_somegame.cs b/Harmony/Documentation/examples/intro_somegame.cs index a7f3420c..b666a51a 100644 --- a/Harmony/Documentation/examples/intro_somegame.cs +++ b/Harmony/Documentation/examples/intro_somegame.cs @@ -16,4 +16,4 @@ private int DoSomething() } } // -} \ No newline at end of file +} diff --git a/Harmony/Documentation/examples/patching-auxilary.cs b/Harmony/Documentation/examples/patching-auxilary.cs index 5ff1d9d0..21361fed 100644 --- a/Harmony/Documentation/examples/patching-auxilary.cs +++ b/Harmony/Documentation/examples/patching-auxilary.cs @@ -18,4 +18,4 @@ static IEnumerable TargetMethods() } // } -} \ No newline at end of file +} diff --git a/Harmony/Documentation/examples/patching-edgecases.cs b/Harmony/Documentation/examples/patching-edgecases.cs index e4282863..b99a8089 100644 --- a/Harmony/Documentation/examples/patching-edgecases.cs +++ b/Harmony/Documentation/examples/patching-edgecases.cs @@ -37,4 +37,4 @@ public override string Method() } } // -} \ No newline at end of file +} diff --git a/Harmony/Documentation/examples/patching-finalizer.cs b/Harmony/Documentation/examples/patching-finalizer.cs index b2183bc3..1babf68e 100644 --- a/Harmony/Documentation/examples/patching-finalizer.cs +++ b/Harmony/Documentation/examples/patching-finalizer.cs @@ -27,4 +27,4 @@ static Exception Finalizer(Exception __exception) } // } -} \ No newline at end of file +} diff --git a/Harmony/Documentation/examples/patching-postfix.cs b/Harmony/Documentation/examples/patching-postfix.cs index 002a886e..6eb111c9 100644 --- a/Harmony/Documentation/examples/patching-postfix.cs +++ b/Harmony/Documentation/examples/patching-postfix.cs @@ -93,4 +93,4 @@ static void Prefix(int counter) } // } -} \ No newline at end of file +} diff --git a/Harmony/Documentation/examples/patching-prefix.cs b/Harmony/Documentation/examples/patching-prefix.cs index 295c9444..888f8dd0 100644 --- a/Harmony/Documentation/examples/patching-prefix.cs +++ b/Harmony/Documentation/examples/patching-prefix.cs @@ -111,4 +111,4 @@ static void Postfix(Stopwatch __state) } // } -} \ No newline at end of file +} diff --git a/Harmony/Documentation/examples/patching-transpiler.cs b/Harmony/Documentation/examples/patching-transpiler.cs index fd1e6414..80b69d93 100644 --- a/Harmony/Documentation/examples/patching-transpiler.cs +++ b/Harmony/Documentation/examples/patching-transpiler.cs @@ -105,4 +105,4 @@ class Log public static void Error(string s) { } } } -} \ No newline at end of file +} diff --git a/Harmony/Documentation/examples/priorities.cs b/Harmony/Documentation/examples/priorities.cs index 3ea0f1b3..fb6b7933 100644 --- a/Harmony/Documentation/examples/priorities.cs +++ b/Harmony/Documentation/examples/priorities.cs @@ -76,4 +76,4 @@ static void Postfix(ref string result) } // } -} \ No newline at end of file +} diff --git a/Harmony/Documentation/examples/reverse-patching.cs b/Harmony/Documentation/examples/reverse-patching.cs index 16f455ca..9464eec6 100644 --- a/Harmony/Documentation/examples/reverse-patching.cs +++ b/Harmony/Documentation/examples/reverse-patching.cs @@ -95,4 +95,4 @@ IEnumerable Transpiler(IEnumerable instruction } // } -} \ No newline at end of file +} diff --git a/Harmony/Documentation/examples/utilities.cs b/Harmony/Documentation/examples/utilities.cs index dbb8d363..2bfb5653 100644 --- a/Harmony/Documentation/examples/utilities.cs +++ b/Harmony/Documentation/examples/utilities.cs @@ -49,4 +49,4 @@ void Test() } // } -} \ No newline at end of file +} diff --git a/Harmony/Extras/DelegateTypeFactory.cs b/Harmony/Extras/DelegateTypeFactory.cs index 45158a5a..04df458c 100644 --- a/Harmony/Extras/DelegateTypeFactory.cs +++ b/Harmony/Extras/DelegateTypeFactory.cs @@ -51,4 +51,4 @@ public Type CreateDelegateType(MethodInfo method) #endif } } -} \ No newline at end of file +} diff --git a/Harmony/Extras/FastAccess.cs b/Harmony/Extras/FastAccess.cs index 223eeb9a..49a3d1d8 100644 --- a/Harmony/Extras/FastAccess.cs +++ b/Harmony/Extras/FastAccess.cs @@ -172,4 +172,4 @@ static DynamicMethodDefinition CreateSetDynamicMethod(Type type) return new DynamicMethodDefinition($"DynamicSet_{type.Name}", typeof(void), new Type[] { typeof(T), typeof(S) }); } } -} \ No newline at end of file +} diff --git a/Harmony/Extras/MethodInvoker.cs b/Harmony/Extras/MethodInvoker.cs index 9aa8dc25..b97311de 100644 --- a/Harmony/Extras/MethodInvoker.cs +++ b/Harmony/Extras/MethodInvoker.cs @@ -213,4 +213,4 @@ internal static void EmitFastInt(ILGenerator il, int value) il.Emit(OpCodes.Ldc_I4, value); } } -} \ No newline at end of file +} diff --git a/Harmony/Harmony.csproj b/Harmony/Harmony.csproj index 504bf62c..9aaee0d0 100644 --- a/Harmony/Harmony.csproj +++ b/Harmony/Harmony.csproj @@ -96,4 +96,4 @@ - \ No newline at end of file + diff --git a/Harmony/ILRepack.targets b/Harmony/ILRepack.targets index ef635da1..270bf05c 100644 --- a/Harmony/ILRepack.targets +++ b/Harmony/ILRepack.targets @@ -35,4 +35,4 @@ - \ No newline at end of file + diff --git a/Harmony/Internal/AccessCache.cs b/Harmony/Internal/AccessCache.cs index ac4219d9..48f5d5d6 100644 --- a/Harmony/Internal/AccessCache.cs +++ b/Harmony/Internal/AccessCache.cs @@ -89,4 +89,4 @@ internal MethodBase GetMethodInfo(Type type, string name, Type[] arguments, Memb return value; } } -} \ No newline at end of file +} diff --git a/Harmony/Internal/ByteBuffer.cs b/Harmony/Internal/ByteBuffer.cs index 6f8a2e7b..b8897d45 100644 --- a/Harmony/Internal/ByteBuffer.cs +++ b/Harmony/Internal/ByteBuffer.cs @@ -102,4 +102,4 @@ void CheckCanRead(int count) throw new ArgumentOutOfRangeException(); } } -} \ No newline at end of file +} diff --git a/Harmony/Internal/CodeTranspiler.cs b/Harmony/Internal/CodeTranspiler.cs index 7e19e798..850597ad 100644 --- a/Harmony/Internal/CodeTranspiler.cs +++ b/Harmony/Internal/CodeTranspiler.cs @@ -284,4 +284,4 @@ static OpCode ReplaceShortJumps(OpCode opcode) return opcode; } } -} \ No newline at end of file +} diff --git a/Harmony/Internal/Emitter.cs b/Harmony/Internal/Emitter.cs index 47f37142..27e93010 100644 --- a/Harmony/Internal/Emitter.cs +++ b/Harmony/Internal/Emitter.cs @@ -375,4 +375,4 @@ internal void EmitCalli(OpCode opcode, CallingConventions callingConvention, Typ il.EmitCalli(opcode, callingConvention, returnType, parameterTypes, optionalParameterTypes); } } -} \ No newline at end of file +} diff --git a/Harmony/Internal/HarmonySharedState.cs b/Harmony/Internal/HarmonySharedState.cs index 3ddc4bfa..102dbb83 100644 --- a/Harmony/Internal/HarmonySharedState.cs +++ b/Harmony/Internal/HarmonySharedState.cs @@ -92,4 +92,4 @@ internal static void UpdatePatchInfo(MethodBase method, PatchInfo patchInfo) GetState()[method] = patchInfo.Serialize(); } } -} \ No newline at end of file +} diff --git a/Harmony/Internal/ILInstruction.cs b/Harmony/Internal/ILInstruction.cs index 6085691a..a5187a87 100644 --- a/Harmony/Internal/ILInstruction.cs +++ b/Harmony/Internal/ILInstruction.cs @@ -120,4 +120,4 @@ static void AppendLabel(ref string str, object argument) str += $"IL_{instruction?.offset.ToString("X4") ?? argument}"; } } -} \ No newline at end of file +} diff --git a/Harmony/Internal/Memory.cs b/Harmony/Internal/Memory.cs index 9ea2a184..fa7e42cc 100644 --- a/Harmony/Internal/Memory.cs +++ b/Harmony/Internal/Memory.cs @@ -80,4 +80,4 @@ public static long GetMethodStart(MethodBase method, out Exception exception) } } } -} \ No newline at end of file +} diff --git a/Harmony/Internal/MethodCopier.cs b/Harmony/Internal/MethodCopier.cs index ecc63dfd..a50c9abb 100644 --- a/Harmony/Internal/MethodCopier.cs +++ b/Harmony/Internal/MethodCopier.cs @@ -719,4 +719,4 @@ internal ThisParameter(MethodBase method) } } } -} \ No newline at end of file +} diff --git a/Harmony/Internal/MethodPatcher.cs b/Harmony/Internal/MethodPatcher.cs index 41a5f0ef..9bcda021 100644 --- a/Harmony/Internal/MethodPatcher.cs +++ b/Harmony/Internal/MethodPatcher.cs @@ -668,4 +668,4 @@ bool AddFinalizers(Dictionary variables, bool catchExcepti return rethrowPossible; } } -} \ No newline at end of file +} diff --git a/Harmony/Internal/PatchArgumentExtensions.cs b/Harmony/Internal/PatchArgumentExtensions.cs index 5379d2a7..71d62c96 100644 --- a/Harmony/Internal/PatchArgumentExtensions.cs +++ b/Harmony/Internal/PatchArgumentExtensions.cs @@ -104,4 +104,4 @@ internal static int GetArgumentIndex(this MethodInfo patch, string[] originalPar return -1; } } -} \ No newline at end of file +} diff --git a/Harmony/Internal/PatchFunctions.cs b/Harmony/Internal/PatchFunctions.cs index f8f3846a..479b5912 100644 --- a/Harmony/Internal/PatchFunctions.cs +++ b/Harmony/Internal/PatchFunctions.cs @@ -198,4 +198,4 @@ internal static MethodInfo ReversePatch(HarmonyMethod standin, MethodBase origin return replacement; } } -} \ No newline at end of file +} diff --git a/Harmony/Internal/PatchModels.cs b/Harmony/Internal/PatchModels.cs index 810c1657..c100407b 100644 --- a/Harmony/Internal/PatchModels.cs +++ b/Harmony/Internal/PatchModels.cs @@ -132,4 +132,4 @@ internal static AttributePatch Create(MethodInfo patch) return type; } } -} \ No newline at end of file +} diff --git a/Harmony/Internal/PatchSorter.cs b/Harmony/Internal/PatchSorter.cs index 05840575..f0bcd8d7 100644 --- a/Harmony/Internal/PatchSorter.cs +++ b/Harmony/Internal/PatchSorter.cs @@ -250,4 +250,4 @@ public int GetHashCode(Patch obj) } } } -} \ No newline at end of file +} diff --git a/Harmony/Internal/PatchTools.cs b/Harmony/Internal/PatchTools.cs index 8080d17f..66c7607f 100644 --- a/Harmony/Internal/PatchTools.cs +++ b/Harmony/Internal/PatchTools.cs @@ -84,4 +84,4 @@ internal static MethodBase GetOriginalMethod(this HarmonyMethod attr) return null; } } -} \ No newline at end of file +} diff --git a/Harmony/Internal/StructReturnBufferCheck.cs b/Harmony/Internal/StructReturnBufferCheck.cs index d3e4b0e0..901dc3be 100644 --- a/Harmony/Internal/StructReturnBufferCheck.cs +++ b/Harmony/Internal/StructReturnBufferCheck.cs @@ -204,4 +204,4 @@ internal static void ArgumentShifter(List instructions, bool sh } } } -} \ No newline at end of file +} diff --git a/Harmony/Properties/AssemblyInfo.cs b/Harmony/Properties/AssemblyInfo.cs index 5c5ca9e4..21a0f898 100644 --- a/Harmony/Properties/AssemblyInfo.cs +++ b/Harmony/Properties/AssemblyInfo.cs @@ -8,4 +8,4 @@ // require Harmony to expose its internals instead. // This is only relevant for when MonoMod.Common gets merged into Harmony. [assembly: InternalsVisibleTo("MonoMod.Utils.Cil.ILGeneratorProxy")] -[assembly: Guid("69aee16a-b6e7-4642-8081-3928b32455df")] \ No newline at end of file +[assembly: Guid("69aee16a-b6e7-4642-8081-3928b32455df")] diff --git a/Harmony/Public/Attributes.cs b/Harmony/Public/Attributes.cs index 9eeb448a..e7f88393 100644 --- a/Harmony/Public/Attributes.cs +++ b/Harmony/Public/Attributes.cs @@ -675,4 +675,4 @@ public HarmonyArgument(int index, string name) NewName = name; } } -} \ No newline at end of file +} diff --git a/Harmony/Public/CodeInstruction.cs b/Harmony/Public/CodeInstruction.cs index 2d6303b7..e826b156 100644 --- a/Harmony/Public/CodeInstruction.cs +++ b/Harmony/Public/CodeInstruction.cs @@ -192,4 +192,4 @@ public override string ToString() return opcode + operandStr + extras; } } -} \ No newline at end of file +} diff --git a/Harmony/Public/ExceptionBlock.cs b/Harmony/Public/ExceptionBlock.cs index 0e1318b0..627e4b34 100644 --- a/Harmony/Public/ExceptionBlock.cs +++ b/Harmony/Public/ExceptionBlock.cs @@ -53,4 +53,4 @@ public ExceptionBlock(ExceptionBlockType blockType, Type catchType = null) this.catchType = catchType ?? typeof(object); } } -} \ No newline at end of file +} diff --git a/Harmony/Public/Harmony.cs b/Harmony/Public/Harmony.cs index f22eed29..d4087e4c 100644 --- a/Harmony/Public/Harmony.cs +++ b/Harmony/Public/Harmony.cs @@ -226,4 +226,4 @@ public static Dictionary VersionInfo(out Version currentVersion return PatchProcessor.VersionInfo(out currentVersion); } } -} \ No newline at end of file +} diff --git a/Harmony/Public/HarmonyException.cs b/Harmony/Public/HarmonyException.cs index ec04e374..364143d3 100644 --- a/Harmony/Public/HarmonyException.cs +++ b/Harmony/Public/HarmonyException.cs @@ -82,4 +82,4 @@ public int GetErrorIndex() return -1; } } -} \ No newline at end of file +} diff --git a/Harmony/Public/HarmonyMethod.cs b/Harmony/Public/HarmonyMethod.cs index a5402eba..2d81fd4e 100644 --- a/Harmony/Public/HarmonyMethod.cs +++ b/Harmony/Public/HarmonyMethod.cs @@ -288,4 +288,4 @@ public static HarmonyMethod GetMergedFromMethod(MethodBase method) return HarmonyMethod.Merge(GetFromMethod(method)); } } -} \ No newline at end of file +} diff --git a/Harmony/Public/InlineSignature.cs b/Harmony/Public/InlineSignature.cs index cf0ad556..273d972b 100644 --- a/Harmony/Public/InlineSignature.cs +++ b/Harmony/Public/InlineSignature.cs @@ -119,4 +119,4 @@ internal TypeReference ToTypeReference(ModuleDefinition module) } } } -} \ No newline at end of file +} diff --git a/Harmony/Public/Patch.cs b/Harmony/Public/Patch.cs index 5f0a9034..e5239eb3 100644 --- a/Harmony/Public/Patch.cs +++ b/Harmony/Public/Patch.cs @@ -373,4 +373,4 @@ public override int GetHashCode() return PatchMethod.GetHashCode(); } } -} \ No newline at end of file +} diff --git a/Harmony/Public/PatchProcessor.cs b/Harmony/Public/PatchProcessor.cs index 17a21522..6d17458c 100644 --- a/Harmony/Public/PatchProcessor.cs +++ b/Harmony/Public/PatchProcessor.cs @@ -335,4 +335,4 @@ public static IEnumerable> ReadMethodBody(MethodBas .Select(instr => new KeyValuePair(instr.opcode, instr.operand)); } } -} \ No newline at end of file +} diff --git a/Harmony/Public/Patches.cs b/Harmony/Public/Patches.cs index f3499235..cb5cf3eb 100644 --- a/Harmony/Public/Patches.cs +++ b/Harmony/Public/Patches.cs @@ -59,4 +59,4 @@ public Patches(Patch[] prefixes, Patch[] postfixes, Patch[] transpilers, Patch[] Finalizers = finalizers.ToList().AsReadOnly(); } } -} \ No newline at end of file +} diff --git a/Harmony/Public/Priority.cs b/Harmony/Public/Priority.cs index 7b0e333a..ac37c75e 100644 --- a/Harmony/Public/Priority.cs +++ b/Harmony/Public/Priority.cs @@ -40,4 +40,4 @@ public static class Priority /// public const int First = 800; } -} \ No newline at end of file +} diff --git a/Harmony/Public/ReversePatcher.cs b/Harmony/Public/ReversePatcher.cs index 393eefe6..c203a64c 100644 --- a/Harmony/Public/ReversePatcher.cs +++ b/Harmony/Public/ReversePatcher.cs @@ -51,4 +51,4 @@ internal static MethodInfo GetTranspiler(MethodInfo method) }); } } -} \ No newline at end of file +} diff --git a/Harmony/Public/Transpilers.cs b/Harmony/Public/Transpilers.cs index 542d92c9..73883bea 100644 --- a/Harmony/Public/Transpilers.cs +++ b/Harmony/Public/Transpilers.cs @@ -68,4 +68,4 @@ public static IEnumerable DebugLogger(this IEnumerable objects) return hash1 + (hash2 * 1566083941); } } -} \ No newline at end of file +} diff --git a/Harmony/Tools/Extensions.cs b/Harmony/Tools/Extensions.cs index 07d43bc3..2865f588 100644 --- a/Harmony/Tools/Extensions.cs +++ b/Harmony/Tools/Extensions.cs @@ -619,4 +619,4 @@ public static bool HasMethodBody(this MethodBase member) return (member.GetMethodBody()?.GetILAsByteArray()?.Length ?? 0) > 0; } } -} \ No newline at end of file +} diff --git a/Harmony/Tools/FileLog.cs b/Harmony/Tools/FileLog.cs index a9d629b0..d38c2cce 100644 --- a/Harmony/Tools/FileLog.cs +++ b/Harmony/Tools/FileLog.cs @@ -169,4 +169,4 @@ public static unsafe void LogBytes(long ptr, int len) } } } -} \ No newline at end of file +} diff --git a/Harmony/Tools/SymbolExtensions.cs b/Harmony/Tools/SymbolExtensions.cs index c17474a0..2a95dd67 100644 --- a/Harmony/Tools/SymbolExtensions.cs +++ b/Harmony/Tools/SymbolExtensions.cs @@ -56,4 +56,4 @@ public static MethodInfo GetMethodInfo(LambdaExpression expression) return method; } } -} \ No newline at end of file +} diff --git a/Harmony/Tools/Traverse.cs b/Harmony/Tools/Traverse.cs index d6bc17e6..0b7d70cb 100644 --- a/Harmony/Tools/Traverse.cs +++ b/Harmony/Tools/Traverse.cs @@ -458,4 +458,4 @@ public override string ToString() return value?.ToString(); } } -} \ No newline at end of file +} diff --git a/HarmonyTests/Extras/Assets/MethodInvokerClasses.cs b/HarmonyTests/Extras/Assets/MethodInvokerClasses.cs index f74819db..7a5ca8eb 100644 --- a/HarmonyTests/Extras/Assets/MethodInvokerClasses.cs +++ b/HarmonyTests/Extras/Assets/MethodInvokerClasses.cs @@ -27,4 +27,4 @@ public static void Method1(int a, ref int b, out int c, out TestMethodInvokerObj e.Value = a; } } -} \ No newline at end of file +} diff --git a/HarmonyTests/Extras/TestMethodInvoker.cs b/HarmonyTests/Extras/TestMethodInvoker.cs index db0e0e4f..cd54d885 100644 --- a/HarmonyTests/Extras/TestMethodInvoker.cs +++ b/HarmonyTests/Extras/TestMethodInvoker.cs @@ -62,4 +62,4 @@ public void Test_MethodInvokerSelfObject() Assert.AreEqual(3, instance.Value); } } -} \ No newline at end of file +} diff --git a/HarmonyTests/HarmonyTests.csproj b/HarmonyTests/HarmonyTests.csproj index 067115b7..8dbf10b1 100644 --- a/HarmonyTests/HarmonyTests.csproj +++ b/HarmonyTests/HarmonyTests.csproj @@ -60,4 +60,4 @@ - \ No newline at end of file + diff --git a/HarmonyTests/IL/DynamicArgumentPatches.cs b/HarmonyTests/IL/DynamicArgumentPatches.cs index 08cd7c4d..9eb1b6aa 100644 --- a/HarmonyTests/IL/DynamicArgumentPatches.cs +++ b/HarmonyTests/IL/DynamicArgumentPatches.cs @@ -232,4 +232,4 @@ public void Test_SendingArguments() Assert.AreEqual(log[n++], "System.Collections.Generic.List`1[System.Int32]"); } } -} \ No newline at end of file +} diff --git a/HarmonyTests/IL/Instructions.cs b/HarmonyTests/IL/Instructions.cs index 4ba9f1d2..1a51bb2a 100644 --- a/HarmonyTests/IL/Instructions.cs +++ b/HarmonyTests/IL/Instructions.cs @@ -1,4 +1,4 @@ -using HarmonyLib; +using HarmonyLib; using NUnit.Framework; using System.Reflection.Emit; @@ -15,4 +15,4 @@ public void Test_MalformedStringOperand() Assert.AreEqual($"ldstr \"{expectedOperand}\"", inst.ToString()); } } -} \ No newline at end of file +} diff --git a/HarmonyTests/IL/TestMethodBodyReader.cs b/HarmonyTests/IL/TestMethodBodyReader.cs index a212e782..f238b254 100644 --- a/HarmonyTests/IL/TestMethodBodyReader.cs +++ b/HarmonyTests/IL/TestMethodBodyReader.cs @@ -72,4 +72,4 @@ public int Compare(object x, object y) } } } -} \ No newline at end of file +} diff --git a/HarmonyTests/Patching/Arguments.cs b/HarmonyTests/Patching/Arguments.cs index 4cc38f55..5f8d4174 100644 --- a/HarmonyTests/Patching/Arguments.cs +++ b/HarmonyTests/Patching/Arguments.cs @@ -173,4 +173,4 @@ public void Test_InjectDelegateForValueType() Assert.AreEqual("{123}/{456}", instance.Method(4444)); } } -} \ No newline at end of file +} diff --git a/HarmonyTests/Patching/Assets/CombinedPatchClass.cs b/HarmonyTests/Patching/Assets/CombinedPatchClass.cs index fa9c3fd8..bb140b14 100644 --- a/HarmonyTests/Patching/Assets/CombinedPatchClass.cs +++ b/HarmonyTests/Patching/Assets/CombinedPatchClass.cs @@ -61,4 +61,4 @@ static Exception Finalizer4() return null; } } -} \ No newline at end of file +} diff --git a/HarmonyTests/Patching/Assets/FinalizerPatchClasses.cs b/HarmonyTests/Patching/Assets/FinalizerPatchClasses.cs index e0f4dc57..d6c53804 100644 --- a/HarmonyTests/Patching/Assets/FinalizerPatchClasses.cs +++ b/HarmonyTests/Patching/Assets/FinalizerPatchClasses.cs @@ -148,4 +148,4 @@ public static Exception Finalizer(Exception __exception, ref string __result) return new ReplacedException(); } } -} \ No newline at end of file +} diff --git a/HarmonyTests/Patching/Assets/PatchClasses.cs b/HarmonyTests/Patching/Assets/PatchClasses.cs index c095665c..c439331d 100644 --- a/HarmonyTests/Patching/Assets/PatchClasses.cs +++ b/HarmonyTests/Patching/Assets/PatchClasses.cs @@ -1177,4 +1177,4 @@ public static int Method(Exception exception) } } */ -} \ No newline at end of file +} diff --git a/HarmonyTests/Patching/Assets/ReturningStructMethods.cs b/HarmonyTests/Patching/Assets/ReturningStructMethods.cs index c6c6dd85..1c650440 100644 --- a/HarmonyTests/Patching/Assets/ReturningStructMethods.cs +++ b/HarmonyTests/Patching/Assets/ReturningStructMethods.cs @@ -255,4 +255,4 @@ public static St20 SM20(string s) return default; } } -} \ No newline at end of file +} diff --git a/HarmonyTests/Patching/Assets/ReturningStructs.cs b/HarmonyTests/Patching/Assets/ReturningStructs.cs index e319c36c..8eec6eb1 100644 --- a/HarmonyTests/Patching/Assets/ReturningStructs.cs +++ b/HarmonyTests/Patching/Assets/ReturningStructs.cs @@ -289,4 +289,4 @@ public struct St20 public byte b19; public byte b20; } -} \ No newline at end of file +} diff --git a/HarmonyTests/Patching/Assets/Specials.cs b/HarmonyTests/Patching/Assets/Specials.cs index 647e36b4..ad38a32a 100644 --- a/HarmonyTests/Patching/Assets/Specials.cs +++ b/HarmonyTests/Patching/Assets/Specials.cs @@ -169,4 +169,4 @@ static IEnumerable Transpiler(IEnumerable inst yield return new CodeInstruction(OpCodes.Ret); } } -} \ No newline at end of file +} diff --git a/HarmonyTests/Patching/CombinedPatches.cs b/HarmonyTests/Patching/CombinedPatches.cs index 717ec5e7..a981fde7 100644 --- a/HarmonyTests/Patching/CombinedPatches.cs +++ b/HarmonyTests/Patching/CombinedPatches.cs @@ -57,4 +57,4 @@ public static void Test_Method11() Assert.AreEqual("Postfix1", Class14.state[5]); } } -} \ No newline at end of file +} diff --git a/HarmonyTests/Patching/DynamicMethodPatches.cs b/HarmonyTests/Patching/DynamicMethodPatches.cs index 9badd4fc..3c83dd17 100644 --- a/HarmonyTests/Patching/DynamicMethodPatches.cs +++ b/HarmonyTests/Patching/DynamicMethodPatches.cs @@ -39,4 +39,4 @@ public void Test_ByRefResultPrefix() Assert.AreEqual("patched", result); } } -} \ No newline at end of file +} diff --git a/HarmonyTests/Patching/Exceptions.cs b/HarmonyTests/Patching/Exceptions.cs index 58bc3395..52786326 100644 --- a/HarmonyTests/Patching/Exceptions.cs +++ b/HarmonyTests/Patching/Exceptions.cs @@ -27,4 +27,4 @@ public void TestPlainMethodExceptions() } */ } -} \ No newline at end of file +} diff --git a/HarmonyTests/Patching/FinalizerPatches.cs b/HarmonyTests/Patching/FinalizerPatches.cs index 8d835aa9..14727734 100644 --- a/HarmonyTests/Patching/FinalizerPatches.cs +++ b/HarmonyTests/Patching/FinalizerPatches.cs @@ -295,4 +295,4 @@ private void AssertExceptionInput() Assert.IsInstanceOf(typeof(E), info["exception"]); } } -} \ No newline at end of file +} diff --git a/HarmonyTests/Patching/GenericsPatches.cs b/HarmonyTests/Patching/GenericsPatches.cs index 2f1a4c2a..fe959275 100644 --- a/HarmonyTests/Patching/GenericsPatches.cs +++ b/HarmonyTests/Patching/GenericsPatches.cs @@ -176,4 +176,4 @@ public void Test_GenericsOriginalMethod() Assert.AreEqual(originalMethod, Class13Patch.method); } } -} \ No newline at end of file +} diff --git a/HarmonyTests/Patching/PatchSorting.cs b/HarmonyTests/Patching/PatchSorting.cs index 3379cb2c..e535fe4d 100644 --- a/HarmonyTests/Patching/PatchSorting.cs +++ b/HarmonyTests/Patching/PatchSorting.cs @@ -335,4 +335,4 @@ public void Test_PatchSorterCache0() Assert.False(sorter.ComparePatchLists(patchInstances), "After of patch changed"); } } -} \ No newline at end of file +} diff --git a/HarmonyTests/Patching/Specials.cs b/HarmonyTests/Patching/Specials.cs index dd670a95..6213fe77 100644 --- a/HarmonyTests/Patching/Specials.cs +++ b/HarmonyTests/Patching/Specials.cs @@ -236,4 +236,4 @@ public void Test_PatchExternalMethod() _ = patcher.Patch(); } } -} \ No newline at end of file +} diff --git a/HarmonyTests/Patching/StaticPatches.cs b/HarmonyTests/Patching/StaticPatches.cs index 3b4e80e2..bb962993 100644 --- a/HarmonyTests/Patching/StaticPatches.cs +++ b/HarmonyTests/Patching/StaticPatches.cs @@ -403,4 +403,4 @@ public void Test_Class18() Assert.AreEqual((float)1, color.r); } } -} \ No newline at end of file +} diff --git a/HarmonyTests/Patching/TargetMethod.cs b/HarmonyTests/Patching/TargetMethod.cs index dfc2ebfb..ad2edb92 100644 --- a/HarmonyTests/Patching/TargetMethod.cs +++ b/HarmonyTests/Patching/TargetMethod.cs @@ -86,4 +86,4 @@ public void Test_TargetMethods_Returns_Null() Assert.True(exception.InnerException.Message.Contains("returned an unexpected result: some element was null")); } } -} \ No newline at end of file +} diff --git a/HarmonyTests/Patching/Transpiling.cs b/HarmonyTests/Patching/Transpiling.cs index 600e0f4c..4d0d1145 100644 --- a/HarmonyTests/Patching/Transpiling.cs +++ b/HarmonyTests/Patching/Transpiling.cs @@ -98,4 +98,4 @@ public static IEnumerable LazyTranspiler(IEnumerable().Join(module => module.FileName, "\n")); } } -} \ No newline at end of file +} diff --git a/HarmonyTests/TestTools.cs b/HarmonyTests/TestTools.cs index 89a1da2a..fd308277 100644 --- a/HarmonyTests/TestTools.cs +++ b/HarmonyTests/TestTools.cs @@ -370,4 +370,4 @@ public void BaseTearDown() TestTools.Log($"--- {result.FullName} => {result.ResultState}", indentLevel: 0); } } -} \ No newline at end of file +} diff --git a/HarmonyTests/Tools/Assets/AccessToolsClass.cs b/HarmonyTests/Tools/Assets/AccessToolsClass.cs index 73feb75a..9b0b9305 100644 --- a/HarmonyTests/Tools/Assets/AccessToolsClass.cs +++ b/HarmonyTests/Tools/Assets/AccessToolsClass.cs @@ -208,4 +208,4 @@ private string SomeMethod(string s) [HarmonyDelegate(typeof(Foo), "SomeMethod")] public delegate string FooSomeMethod(Foo foo, string s); } -} \ No newline at end of file +} diff --git a/HarmonyTests/Tools/Assets/AttributesClass.cs b/HarmonyTests/Tools/Assets/AttributesClass.cs index 3e7281c1..2333a4f1 100644 --- a/HarmonyTests/Tools/Assets/AttributesClass.cs +++ b/HarmonyTests/Tools/Assets/AttributesClass.cs @@ -69,4 +69,4 @@ public static void Prefix() { } } -} \ No newline at end of file +} diff --git a/HarmonyTests/Tools/TestAccessCache.cs b/HarmonyTests/Tools/TestAccessCache.cs index dfe980cb..a56c692b 100644 --- a/HarmonyTests/Tools/TestAccessCache.cs +++ b/HarmonyTests/Tools/TestAccessCache.cs @@ -115,4 +115,4 @@ public void Test_AccessCache_Method() Assert.AreNotSame(minfo3, minfo4); } } -} \ No newline at end of file +} diff --git a/HarmonyTests/Tools/TestAccessTools.cs b/HarmonyTests/Tools/TestAccessTools.cs index 0d2a7f18..bda283ee 100644 --- a/HarmonyTests/Tools/TestAccessTools.cs +++ b/HarmonyTests/Tools/TestAccessTools.cs @@ -518,4 +518,4 @@ public void Test_AccessTools_HarmonyDelegate() Assert.AreEqual("[test]", someMethod(foo, "test")); } } -} \ No newline at end of file +} diff --git a/HarmonyTests/Tools/TestAttributes.cs b/HarmonyTests/Tools/TestAttributes.cs index fb7e5459..75696c50 100644 --- a/HarmonyTests/Tools/TestAttributes.cs +++ b/HarmonyTests/Tools/TestAttributes.cs @@ -1,4 +1,4 @@ -using HarmonyLib; +using HarmonyLib; using HarmonyLibTests.Assets; using NUnit.Framework; @@ -47,4 +47,4 @@ public void Test_SubClassPatching() } } } -} \ No newline at end of file +} diff --git a/HarmonyTests/Tools/TestGettingInstructions.cs b/HarmonyTests/Tools/TestGettingInstructions.cs index 1aabc7b2..c31716b4 100644 --- a/HarmonyTests/Tools/TestGettingInstructions.cs +++ b/HarmonyTests/Tools/TestGettingInstructions.cs @@ -68,4 +68,4 @@ public void Test_GetCurrentInstructions() Assert.Fail("Instruction " + i + " differs"); } } -} \ No newline at end of file +} diff --git a/HarmonyTests/Traverse/Assets/TraverseFields_AccessModifiers.cs b/HarmonyTests/Traverse/Assets/TraverseFields_AccessModifiers.cs index ab354925..36d20a1c 100644 --- a/HarmonyTests/Traverse/Assets/TraverseFields_AccessModifiers.cs +++ b/HarmonyTests/Traverse/Assets/TraverseFields_AccessModifiers.cs @@ -43,4 +43,4 @@ public override string ToString() return "TraverseFields_AccessModifiers"; } } -} \ No newline at end of file +} diff --git a/HarmonyTests/Traverse/Assets/TraverseMethods.cs b/HarmonyTests/Traverse/Assets/TraverseMethods.cs index 87f2085b..2e694863 100644 --- a/HarmonyTests/Traverse/Assets/TraverseMethods.cs +++ b/HarmonyTests/Traverse/Assets/TraverseMethods.cs @@ -82,4 +82,4 @@ public int SomeMethod(string p1, int p2, bool p3 = true) return 0; } } -} \ No newline at end of file +} diff --git a/HarmonyTests/Traverse/Assets/TraverseProperties_AccessModifiers.cs b/HarmonyTests/Traverse/Assets/TraverseProperties_AccessModifiers.cs index 061dac7c..8c991791 100644 --- a/HarmonyTests/Traverse/Assets/TraverseProperties_AccessModifiers.cs +++ b/HarmonyTests/Traverse/Assets/TraverseProperties_AccessModifiers.cs @@ -177,4 +177,4 @@ public class TraverseProperties_SubClass : Traverse_BaseClass #pragma warning restore IDE0052 #pragma warning restore CS0414 -} \ No newline at end of file +} diff --git a/HarmonyTests/Traverse/Assets/TraverseTypes.cs b/HarmonyTests/Traverse/Assets/TraverseTypes.cs index 424930e0..74c79b67 100644 --- a/HarmonyTests/Traverse/Assets/TraverseTypes.cs +++ b/HarmonyTests/Traverse/Assets/TraverseTypes.cs @@ -103,4 +103,4 @@ public TraverseNestedTypes(string staticValue) } } -} \ No newline at end of file +} diff --git a/HarmonyTests/Traverse/TestTraverse_Basics.cs b/HarmonyTests/Traverse/TestTraverse_Basics.cs index e7577eed..4d992d68 100644 --- a/HarmonyTests/Traverse/TestTraverse_Basics.cs +++ b/HarmonyTests/Traverse/TestTraverse_Basics.cs @@ -134,4 +134,4 @@ public void Test_Traverse_Create_Type_ToString() Assert.AreEqual(type.ToString(), trv.ToString()); } } -} \ No newline at end of file +} diff --git a/HarmonyTests/Traverse/TestTraverse_Fields.cs b/HarmonyTests/Traverse/TestTraverse_Fields.cs index 5dfc605f..96c81307 100644 --- a/HarmonyTests/Traverse/TestTraverse_Fields.cs +++ b/HarmonyTests/Traverse/TestTraverse_Fields.cs @@ -119,4 +119,4 @@ public void Traverse_Field_SetValue() } } } -} \ No newline at end of file +} diff --git a/HarmonyTests/Traverse/TestTraverse_Methods.cs b/HarmonyTests/Traverse/TestTraverse_Methods.cs index 9b1580a4..2c1fd106 100644 --- a/HarmonyTests/Traverse/TestTraverse_Methods.cs +++ b/HarmonyTests/Traverse/TestTraverse_Methods.cs @@ -81,4 +81,4 @@ public void Traverse_Method_Overloads() Assert.AreEqual(false, mtrv1.GetValue("test", true)); } } -} \ No newline at end of file +} diff --git a/HarmonyTests/Traverse/TestTraverse_Properties.cs b/HarmonyTests/Traverse/TestTraverse_Properties.cs index 9f815102..224c42be 100644 --- a/HarmonyTests/Traverse/TestTraverse_Properties.cs +++ b/HarmonyTests/Traverse/TestTraverse_Properties.cs @@ -80,4 +80,4 @@ public void Traverse_Property_SetValue() } } } -} \ No newline at end of file +} diff --git a/HarmonyTests/Traverse/TestTraverse_Types.cs b/HarmonyTests/Traverse/TestTraverse_Types.cs index f75788f6..1fd3ceb5 100644 --- a/HarmonyTests/Traverse/TestTraverse_Types.cs +++ b/HarmonyTests/Traverse/TestTraverse_Types.cs @@ -76,4 +76,4 @@ public void Traverse_InnerStatic() Assert.AreEqual("somevalue2", value); } } -} \ No newline at end of file +} diff --git a/_config.yml b/_config.yml index c4192631..277f1f2c 100644 --- a/_config.yml +++ b/_config.yml @@ -1 +1 @@ -theme: jekyll-theme-cayman \ No newline at end of file +theme: jekyll-theme-cayman diff --git a/global.json b/global.json index a8ab760d..47a7fa60 100644 --- a/global.json +++ b/global.json @@ -2,4 +2,4 @@ "sdk": { "allowPrerelease": false } -} \ No newline at end of file +}