9 lines
252 B
C#
9 lines
252 B
C#
|
namespace SharpChat;
|
||
|
|
||
|
public readonly struct ValueDiff<T>(T before, T? after) : Diff where T : struct {
|
||
|
public readonly T Before = before;
|
||
|
public readonly T After = after ?? before;
|
||
|
|
||
|
public readonly bool Changed => !Before.Equals(After);
|
||
|
}
|