From d6574f025b4584128a4dc3787882653262dd0a77 Mon Sep 17 00:00:00 2001 From: Raul Santos Date: Tue, 23 Aug 2022 11:08:59 +0200 Subject: [PATCH] Seal classes that can't be inherited from --- .../GodotSharp/Core/Bridge/GodotSerializationInfo.cs | 2 +- modules/mono/glue/GodotSharp/GodotSharp/Variant.cs | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/modules/mono/glue/GodotSharp/GodotSharp/Core/Bridge/GodotSerializationInfo.cs b/modules/mono/glue/GodotSharp/GodotSharp/Core/Bridge/GodotSerializationInfo.cs index 8f26967dcd08..6d20f950076f 100644 --- a/modules/mono/glue/GodotSharp/GodotSharp/Core/Bridge/GodotSerializationInfo.cs +++ b/modules/mono/glue/GodotSharp/GodotSharp/Core/Bridge/GodotSerializationInfo.cs @@ -4,7 +4,7 @@ namespace Godot.Bridge; -public class GodotSerializationInfo : IDisposable +public sealed class GodotSerializationInfo : IDisposable { private readonly Collections.Dictionary _properties; private readonly Collections.Dictionary _signalEvents; diff --git a/modules/mono/glue/GodotSharp/GodotSharp/Variant.cs b/modules/mono/glue/GodotSharp/GodotSharp/Variant.cs index eb8b0611206e..85ef25892203 100644 --- a/modules/mono/glue/GodotSharp/GodotSharp/Variant.cs +++ b/modules/mono/glue/GodotSharp/GodotSharp/Variant.cs @@ -14,7 +14,7 @@ public partial struct Variant : IDisposable private object? _obj; private Disposer? _disposer; - private class Disposer : IDisposable + private sealed class Disposer : IDisposable { private godot_variant.movable _native; @@ -37,7 +37,7 @@ public void Dispose() GC.SuppressFinalize(this); } - public void Dispose(bool disposing) + private void Dispose(bool disposing) { _native.DangerousSelfRef.Dispose();