mirror of
https://github.com/space-wizards/RobustToolbox.git
synced 2026-02-15 03:30:53 +01:00
Analyzer to check that notnullableflag is being properly used (#3569)
This commit is contained in:
18
Robust.Shared/Analyzers/NotNullableFlagAttribute.cs
Normal file
18
Robust.Shared/Analyzers/NotNullableFlagAttribute.cs
Normal file
@@ -0,0 +1,18 @@
|
||||
using System;
|
||||
|
||||
#if NETSTANDARD2_0
|
||||
namespace Robust.Shared.Analyzers.Implementation;
|
||||
#else
|
||||
namespace Robust.Shared.Analyzers;
|
||||
#endif
|
||||
|
||||
[AttributeUsage(AttributeTargets.Parameter | AttributeTargets.GenericParameter)]
|
||||
public sealed class NotNullableFlagAttribute : Attribute
|
||||
{
|
||||
public readonly string TypeParameterName;
|
||||
|
||||
public NotNullableFlagAttribute(string typeParameterName)
|
||||
{
|
||||
TypeParameterName = typeParameterName;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user