Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

validate v1 #346

Draft
wants to merge 2 commits into
base: v1
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions BitFaster.Caching/BitFaster.Caching.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@
<SymbolPackageFormat>snupkg</SymbolPackageFormat>
<AssemblyVersion>1.0.7.0</AssemblyVersion>
<FileVersion>1.0.7.0</FileVersion>
<EnablePackageValidation>true</EnablePackageValidation>
<PackageValidationBaselineVersion>1.0.3</PackageValidationBaselineVersion>
</PropertyGroup>

<PropertyGroup Condition="'$(GITHUB_ACTIONS)' == 'true'">
Expand Down
4 changes: 3 additions & 1 deletion BitFaster.Caching/ICache.cs
Original file line number Diff line number Diff line change
Expand Up @@ -63,9 +63,11 @@ public interface ICache<K, V>
/// <param name="value">The new value.</param>
void AddOrUpdate(K key, V value);

#if NETCOREAPP3_0_OR_GREATER
/// <summary>
/// Removes all keys and values from the cache.
/// </summary>
void Clear();
void Clear() { }
#endif
}
}
2 changes: 1 addition & 1 deletion BitFaster.Caching/Lifetime.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ namespace BitFaster.Caching
/// lifetime is disposed.
/// </summary>
/// <typeparam name="T">The type of value</typeparam>
public sealed class Lifetime<T> : IDisposable
public class Lifetime<T> : IDisposable
{
private readonly Action onDisposeAction;
private readonly ReferenceCount<T> refCount;
Expand Down
2 changes: 1 addition & 1 deletion BitFaster.Caching/Scoped.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ namespace BitFaster.Caching
/// the wrapped object from being diposed until the calling code completes.
/// </summary>
/// <typeparam name="T">The type of scoped value.</typeparam>
public sealed class Scoped<T> : IDisposable where T : IDisposable
public class Scoped<T> : IDisposable where T : IDisposable
{
private ReferenceCount<T> refCount;
private bool isDisposed;
Expand Down