patch 9.0.1786: Vim9: need instanceof() function
Problem: Vim9: need instanceof() function
Solution: Implement instanceof() builtin
Implemented in the same form as Python's isinstance because it allows
for checking multiple class types at the same time.
closes: #12867
Signed-off-by: Christian Brabandt <cb@256bit.org>
Co-authored-by: LemonBoy <thatlemon@gmail.com>
diff --git a/runtime/doc/usr_41.txt b/runtime/doc/usr_41.txt
index 2112fbb..d5aa79e 100644
--- a/runtime/doc/usr_41.txt
+++ b/runtime/doc/usr_41.txt
@@ -877,6 +877,7 @@
srand() initialize seed used by rand()
Variables: *var-functions*
+ instanceof() check if a variable is an instance of a given class
type() type of a variable as a number
typename() type of a variable as text
islocked() check if a variable is locked