change logging api to accept variadic properties

This commit is contained in:
JOLIMAITRE Matthieu 2024-05-02 16:14:15 +02:00
parent 336efff5c1
commit aab2e60dab
7 changed files with 61 additions and 23 deletions

View file

@ -26,6 +26,10 @@ export class BaseGuesser implements Guessing {
}
}
declare_properties(): string[] {
return ["known".padStart(this.length)];
}
async guess(try_: (guess: string, known: string) => Awaitable<GuessResult>) {
const res = this.expected_result();
if (res.completed) return await try_(res.result, res.result);