@@ -4,6 +4,12 @@ public foreign handler MCTypeEvalIsEmpty(in Target as any, out Value as bool) as
44public foreign handler MCTypeEvalIsNotEmpty(in Target as any, out Value as bool) as undefined binds to "<builtin>"
55public foreign handler MCTypeEvalIsDefined(in Target as optional any, out Value as bool) as undefined binds to "<builtin>"
66public foreign handler MCTypeEvalIsNotDefined(in Target as optional any, out Value as bool) as undefined binds to "<builtin>"
7+ public foreign handler MCTypeEvalIsABoolean(in Target as optional any, out Value as bool) as undefined binds to "<builtin>"
8+ public foreign handler MCTypeEvalIsANumber(in Target as optional any, out Value as bool) as undefined binds to "<builtin>"
9+ public foreign handler MCTypeEvalIsAString(in Target as optional any, out Value as bool) as undefined binds to "<builtin>"
10+ public foreign handler MCTypeEvalIsAData(in Target as optional any, out Value as bool) as undefined binds to "<builtin>"
11+ public foreign handler MCTypeEvalIsAnArray(in Target as optional any, out Value as bool) as undefined binds to "<builtin>"
12+ public foreign handler MCTypeEvalIsAList(in Target as optional any, out Value as bool) as undefined binds to "<builtin>"
713
814/*
915Summary: Determines whether <Target> is empty or not.
@@ -65,4 +71,90 @@ end syntax
6571
6672--
6773
74+ /*
75+ Summary: Determines whether <Target> is a boolean or not.
76+
77+ Target: Any expression
78+ output: Returns true if the given expression <Target> is a boolean, and false if not.
79+
80+ */
81+
82+ syntax IsABoolean is postfix operator with precedence 1
83+ <Target: Expression> "is" "a" "boolean"
84+ begin
85+ MCTypeEvalIsABoolean(Target, output)
86+ end syntax
87+
88+ /*
89+ Summary: Determines whether <Target> is a number or not.
90+
91+ Target: Any expression
92+ output: Returns true if the given expression <Target> is a number, and false if not.
93+
94+ */
95+
96+ syntax IsANumber is postfix operator with precedence 1
97+ <Target: Expression> "is" "a" "number"
98+ begin
99+ MCTypeEvalIsANumber(Target, output)
100+ end syntax
101+
102+ /*
103+ Summary: Determines whether <Target> is a string or not.
104+
105+ Target: Any expression
106+ output: Returns true if the given expression <Target> is a string, and false if not.
107+
108+ */
109+
110+ syntax IsAString is postfix operator with precedence 1
111+ <Target: Expression> "is" "a" "string"
112+ begin
113+ MCTypeEvalIsAString(Target, output)
114+ end syntax
115+
116+ /*
117+ Summary: Determines whether <Target> is a data or not.
118+
119+ Target: Any expression
120+ output: Returns true if the given expression <Target> is a data, and false if not.
121+
122+ */
123+
124+ syntax IsAData is postfix operator with precedence 1
125+ <Target: Expression> "is" "a" "data"
126+ begin
127+ MCTypeEvalIsAData(Target, output)
128+ end syntax
129+
130+ /*
131+ Summary: Determines whether <Target> is an array or not.
132+
133+ Target: Any expression
134+ output: Returns true if the given expression <Target> is an array, and false if not.
135+
136+ */
137+
138+ syntax IsAnArray is postfix operator with precedence 1
139+ <Target: Expression> "is" "an" "array"
140+ begin
141+ MCTypeEvalIsAData(Target, output)
142+ end syntax
143+
144+ /*
145+ Summary: Determines whether <Target> is a list or not.
146+
147+ Target: Any expression
148+ output: Returns true if the given expression <Target> is a list, and false if not.
149+
150+ */
151+
152+ syntax IsAList is postfix operator with precedence 1
153+ <Target: Expression> "is" "a" "list"
154+ begin
155+ MCTypeEvalIsAList(Target, output)
156+ end syntax
157+
158+ --
159+
68160end module
0 commit comments