Skip to content

Commit 7e75510

Browse files
committed
Default VirtualMachine to RandomBestLeastRecentlyViewed
1 parent 74ff8e8 commit 7e75510

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
1111
### Updated
1212

1313
- Complexity scoring for `when:` headers no longer counts `not` operations. This means that `when: $x` and `when: not $x` have the same score of 1.
14+
- `VirtualMachine.ContentSaliencyStrategy` now defaults to `RandomBestLeastRecentlyViewed`, not `First`
1415

1516
### Removed
1617

YarnSpinner/VirtualMachine.cs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -239,6 +239,7 @@ internal VirtualMachine(Library library, IVariableStorage storage)
239239
{
240240
this.Library = library;
241241
this.VariableStorage = storage;
242+
this.ContentSaliencyStrategy = new RandomBestLeastRecentlyViewedSaliencyStrategy(storage);
242243
state = new State();
243244
}
244245

@@ -323,7 +324,7 @@ private set
323324
}
324325
}
325326

326-
public IContentSaliencyStrategy ContentSaliencyStrategy { get; internal set; } = new FirstSaliencyStrategy();
327+
public IContentSaliencyStrategy ContentSaliencyStrategy { get; internal set; }
327328

328329
internal Node? currentNode;
329330

0 commit comments

Comments
 (0)