Skip to content

Commit

Permalink
Added comments to ignore remaining warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
tsimbalar committed Oct 17, 2017
1 parent abd9562 commit f41eaf1
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/Serilog/Capturing/PropertyValueConverter.cs
Original file line number Diff line number Diff line change
Expand Up @@ -247,6 +247,7 @@ bool TryConvertValueTuple(object value, Destructuring destructuring, Type valueT
definition == typeof(ValueTuple<,,,,>) || definition == typeof(ValueTuple<,,,,,>) ||
definition == typeof(ValueTuple<,,,,,,>))
#else
// ReSharper disable once PossibleNullReferenceException
var defn = definition.FullName;
if (defn == "System.ValueTuple`1" || defn == "System.ValueTuple`2" ||
defn == "System.ValueTuple`3" || defn == "System.ValueTuple`4" ||
Expand Down
2 changes: 2 additions & 0 deletions src/Serilog/Context/LogContext.cs
Original file line number Diff line number Diff line change
Expand Up @@ -254,6 +254,8 @@ public DisposableObjectHandle(object o) : base(o)
public override object InitializeLifetimeService()
{
var lease = (ILease)base.InitializeLifetimeService();
// ReSharper disable once PossibleNullReferenceException
// not 100% sure this will never occur ...
lease.Register(LifeTimeSponsor);
return lease;
}
Expand Down
2 changes: 2 additions & 0 deletions src/Serilog/Core/Pipeline/MessageTemplateCache.cs
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,8 @@ public MessageTemplate Parse(string messageTemplate)
return _innerParser.Parse(messageTemplate);

#if HASHTABLE
// ReSharper disable once InconsistentlySynchronizedField
// ignored warning because this is by design
var result = (MessageTemplate)_templates[messageTemplate];
if (result != null)
return result;
Expand Down

0 comments on commit f41eaf1

Please sign in to comment.