m/fzf
1
0
mirror of https://github.com/junegunn/fzf.git synced 2025-11-16 15:23:48 -05:00

Change 'interface{}' to 'any' (#4308)

This commit is contained in:
Gabriel Marin
2025-03-11 07:24:54 +02:00
committed by GitHub
parent aefb9a5bc4
commit 6c104d771e
3 changed files with 4 additions and 4 deletions

View File

@@ -6,7 +6,7 @@ import "sync"
type EventType int
// Events is a type that associates EventType to any data
type Events map[EventType]interface{}
type Events map[EventType]any
// EventBox is used for coordinating events
type EventBox struct {
@@ -36,7 +36,7 @@ func (b *EventBox) Wait(callback func(*Events)) {
}
// Set turns on the event type on the box
func (b *EventBox) Set(event EventType, value interface{}) {
func (b *EventBox) Set(event EventType, value any) {
b.cond.L.Lock()
b.events[event] = value
if _, found := b.ignore[event]; !found {