If this is intentional then so be it but I’d be curious why this is.
So with ground/1 you can pass in multiple variables like ground((X,Y))
and it works, like
?- when(ground((X,Y)),Z=3).
when(ground((X, Y)), Z=3).
?- when(ground((X,Y)),Z=3),X=1.
X = 1,
when(ground((1, Y)), Z=3).
?- when(ground((X,Y)),Z=3),X=1,Y=2.
X = 1,
Y = 2,
Z = 3.
However this doesn’t work with nonvar/1
?- when(nonvar((X,Y)),Z=3).
Z = 3.
Both docs show the same expected argument ground(@Term)
and nonvar(@Term)