Nuitka
The Python compiler
Loading...
Searching...
No Matches
comparisons_lt.h
1// Copyright 2025, Kay Hayen, mailto:kay.hayen@gmail.com find license text at end of file
2
3/* WARNING, this code is GENERATED. Modify the template HelperOperationComparison.c.j2 instead! */
4
5/* This file is included from another C file, help IDEs to still parse it on its own. */
6#ifdef __IDE_ONLY__
7#include "nuitka/prelude.h"
8#endif
9
10/* C helpers for type specialized "<" (LT) comparisons */
11
12/* Code referring to "OBJECT" corresponds to any Python object and "OBJECT" to any Python object. */
13extern PyObject *RICH_COMPARE_LT_OBJECT_OBJECT_OBJECT(PyObject *operand1, PyObject *operand2);
14
15/* Code referring to "OBJECT" corresponds to any Python object and "OBJECT" to any Python object. */
16extern nuitka_bool RICH_COMPARE_LT_NBOOL_OBJECT_OBJECT(PyObject *operand1, PyObject *operand2);
17
18#if PYTHON_VERSION < 0x300
19/* Code referring to "OBJECT" corresponds to any Python object and "STR" to Python2 'str'. */
20extern PyObject *RICH_COMPARE_LT_OBJECT_OBJECT_STR(PyObject *operand1, PyObject *operand2);
21#endif
22
23#if PYTHON_VERSION < 0x300
24/* Code referring to "STR" corresponds to Python2 'str' and "OBJECT" to any Python object. */
25extern PyObject *RICH_COMPARE_LT_OBJECT_STR_OBJECT(PyObject *operand1, PyObject *operand2);
26#endif
27
28#if PYTHON_VERSION < 0x300
29/* Code referring to "STR" corresponds to Python2 'str' and "STR" to Python2 'str'. */
30extern PyObject *RICH_COMPARE_LT_OBJECT_STR_STR(PyObject *operand1, PyObject *operand2);
31#endif
32
33#if PYTHON_VERSION < 0x300
34/* Code referring to "STR" corresponds to Python2 'str' and "STR" to Python2 'str'. */
35extern bool RICH_COMPARE_LT_CBOOL_STR_STR(PyObject *operand1, PyObject *operand2);
36#endif
37
38#if PYTHON_VERSION < 0x300
39/* Code referring to "OBJECT" corresponds to any Python object and "STR" to Python2 'str'. */
40extern nuitka_bool RICH_COMPARE_LT_NBOOL_OBJECT_STR(PyObject *operand1, PyObject *operand2);
41#endif
42
43#if PYTHON_VERSION < 0x300
44/* Code referring to "STR" corresponds to Python2 'str' and "OBJECT" to any Python object. */
45extern nuitka_bool RICH_COMPARE_LT_NBOOL_STR_OBJECT(PyObject *operand1, PyObject *operand2);
46#endif
47
48/* Code referring to "OBJECT" corresponds to any Python object and "UNICODE" to Python2 'unicode', Python3 'str'. */
49extern PyObject *RICH_COMPARE_LT_OBJECT_OBJECT_UNICODE(PyObject *operand1, PyObject *operand2);
50
51/* Code referring to "UNICODE" corresponds to Python2 'unicode', Python3 'str' and "OBJECT" to any Python object. */
52extern PyObject *RICH_COMPARE_LT_OBJECT_UNICODE_OBJECT(PyObject *operand1, PyObject *operand2);
53
54/* Code referring to "UNICODE" corresponds to Python2 'unicode', Python3 'str' and "UNICODE" to Python2 'unicode',
55 * Python3 'str'. */
56extern PyObject *RICH_COMPARE_LT_OBJECT_UNICODE_UNICODE(PyObject *operand1, PyObject *operand2);
57
58/* Code referring to "UNICODE" corresponds to Python2 'unicode', Python3 'str' and "UNICODE" to Python2 'unicode',
59 * Python3 'str'. */
60extern bool RICH_COMPARE_LT_CBOOL_UNICODE_UNICODE(PyObject *operand1, PyObject *operand2);
61
62/* Code referring to "OBJECT" corresponds to any Python object and "UNICODE" to Python2 'unicode', Python3 'str'. */
63extern nuitka_bool RICH_COMPARE_LT_NBOOL_OBJECT_UNICODE(PyObject *operand1, PyObject *operand2);
64
65/* Code referring to "UNICODE" corresponds to Python2 'unicode', Python3 'str' and "OBJECT" to any Python object. */
66extern nuitka_bool RICH_COMPARE_LT_NBOOL_UNICODE_OBJECT(PyObject *operand1, PyObject *operand2);
67
68#if PYTHON_VERSION >= 0x300
69/* Code referring to "OBJECT" corresponds to any Python object and "BYTES" to Python3 'bytes'. */
70extern PyObject *RICH_COMPARE_LT_OBJECT_OBJECT_BYTES(PyObject *operand1, PyObject *operand2);
71#endif
72
73#if PYTHON_VERSION >= 0x300
74/* Code referring to "BYTES" corresponds to Python3 'bytes' and "OBJECT" to any Python object. */
75extern PyObject *RICH_COMPARE_LT_OBJECT_BYTES_OBJECT(PyObject *operand1, PyObject *operand2);
76#endif
77
78#if PYTHON_VERSION >= 0x300
79/* Code referring to "BYTES" corresponds to Python3 'bytes' and "BYTES" to Python3 'bytes'. */
80extern PyObject *RICH_COMPARE_LT_OBJECT_BYTES_BYTES(PyObject *operand1, PyObject *operand2);
81#endif
82
83#if PYTHON_VERSION >= 0x300
84/* Code referring to "BYTES" corresponds to Python3 'bytes' and "BYTES" to Python3 'bytes'. */
85extern bool RICH_COMPARE_LT_CBOOL_BYTES_BYTES(PyObject *operand1, PyObject *operand2);
86#endif
87
88#if PYTHON_VERSION >= 0x300
89/* Code referring to "OBJECT" corresponds to any Python object and "BYTES" to Python3 'bytes'. */
90extern nuitka_bool RICH_COMPARE_LT_NBOOL_OBJECT_BYTES(PyObject *operand1, PyObject *operand2);
91#endif
92
93#if PYTHON_VERSION >= 0x300
94/* Code referring to "BYTES" corresponds to Python3 'bytes' and "OBJECT" to any Python object. */
95extern nuitka_bool RICH_COMPARE_LT_NBOOL_BYTES_OBJECT(PyObject *operand1, PyObject *operand2);
96#endif
97
98#if PYTHON_VERSION < 0x300
99/* Code referring to "OBJECT" corresponds to any Python object and "INT" to Python2 'int'. */
100extern PyObject *RICH_COMPARE_LT_OBJECT_OBJECT_INT(PyObject *operand1, PyObject *operand2);
101#endif
102
103#if PYTHON_VERSION < 0x300
104/* Code referring to "INT" corresponds to Python2 'int' and "OBJECT" to any Python object. */
105extern PyObject *RICH_COMPARE_LT_OBJECT_INT_OBJECT(PyObject *operand1, PyObject *operand2);
106#endif
107
108#if PYTHON_VERSION < 0x300
109/* Code referring to "INT" corresponds to Python2 'int' and "INT" to Python2 'int'. */
110extern PyObject *RICH_COMPARE_LT_OBJECT_INT_INT(PyObject *operand1, PyObject *operand2);
111#endif
112
113#if PYTHON_VERSION < 0x300
114/* Code referring to "INT" corresponds to Python2 'int' and "INT" to Python2 'int'. */
115extern bool RICH_COMPARE_LT_CBOOL_INT_INT(PyObject *operand1, PyObject *operand2);
116#endif
117
118#if PYTHON_VERSION < 0x300
119/* Code referring to "OBJECT" corresponds to any Python object and "INT" to Python2 'int'. */
120extern nuitka_bool RICH_COMPARE_LT_NBOOL_OBJECT_INT(PyObject *operand1, PyObject *operand2);
121#endif
122
123#if PYTHON_VERSION < 0x300
124/* Code referring to "INT" corresponds to Python2 'int' and "OBJECT" to any Python object. */
125extern nuitka_bool RICH_COMPARE_LT_NBOOL_INT_OBJECT(PyObject *operand1, PyObject *operand2);
126#endif
127
128/* Code referring to "OBJECT" corresponds to any Python object and "LONG" to Python2 'long', Python3 'int'. */
129extern PyObject *RICH_COMPARE_LT_OBJECT_OBJECT_LONG(PyObject *operand1, PyObject *operand2);
130
131/* Code referring to "LONG" corresponds to Python2 'long', Python3 'int' and "OBJECT" to any Python object. */
132extern PyObject *RICH_COMPARE_LT_OBJECT_LONG_OBJECT(PyObject *operand1, PyObject *operand2);
133
134/* Code referring to "LONG" corresponds to Python2 'long', Python3 'int' and "LONG" to Python2 'long', Python3 'int'. */
135extern PyObject *RICH_COMPARE_LT_OBJECT_LONG_LONG(PyObject *operand1, PyObject *operand2);
136
137/* Code referring to "LONG" corresponds to Python2 'long', Python3 'int' and "LONG" to Python2 'long', Python3 'int'. */
138extern bool RICH_COMPARE_LT_CBOOL_LONG_LONG(PyObject *operand1, PyObject *operand2);
139
140/* Code referring to "OBJECT" corresponds to any Python object and "LONG" to Python2 'long', Python3 'int'. */
141extern nuitka_bool RICH_COMPARE_LT_NBOOL_OBJECT_LONG(PyObject *operand1, PyObject *operand2);
142
143/* Code referring to "LONG" corresponds to Python2 'long', Python3 'int' and "OBJECT" to any Python object. */
144extern nuitka_bool RICH_COMPARE_LT_NBOOL_LONG_OBJECT(PyObject *operand1, PyObject *operand2);
145
146/* Code referring to "OBJECT" corresponds to any Python object and "FLOAT" to Python 'float'. */
147extern PyObject *RICH_COMPARE_LT_OBJECT_OBJECT_FLOAT(PyObject *operand1, PyObject *operand2);
148
149/* Code referring to "FLOAT" corresponds to Python 'float' and "OBJECT" to any Python object. */
150extern PyObject *RICH_COMPARE_LT_OBJECT_FLOAT_OBJECT(PyObject *operand1, PyObject *operand2);
151
152/* Code referring to "FLOAT" corresponds to Python 'float' and "FLOAT" to Python 'float'. */
153extern PyObject *RICH_COMPARE_LT_OBJECT_FLOAT_FLOAT(PyObject *operand1, PyObject *operand2);
154
155/* Code referring to "FLOAT" corresponds to Python 'float' and "FLOAT" to Python 'float'. */
156extern bool RICH_COMPARE_LT_CBOOL_FLOAT_FLOAT(PyObject *operand1, PyObject *operand2);
157
158/* Code referring to "OBJECT" corresponds to any Python object and "FLOAT" to Python 'float'. */
159extern nuitka_bool RICH_COMPARE_LT_NBOOL_OBJECT_FLOAT(PyObject *operand1, PyObject *operand2);
160
161/* Code referring to "FLOAT" corresponds to Python 'float' and "OBJECT" to any Python object. */
162extern nuitka_bool RICH_COMPARE_LT_NBOOL_FLOAT_OBJECT(PyObject *operand1, PyObject *operand2);
163
164/* Code referring to "OBJECT" corresponds to any Python object and "TUPLE" to Python 'tuple'. */
165extern PyObject *RICH_COMPARE_LT_OBJECT_OBJECT_TUPLE(PyObject *operand1, PyObject *operand2);
166
167/* Code referring to "TUPLE" corresponds to Python 'tuple' and "OBJECT" to any Python object. */
168extern PyObject *RICH_COMPARE_LT_OBJECT_TUPLE_OBJECT(PyObject *operand1, PyObject *operand2);
169
170/* Code referring to "TUPLE" corresponds to Python 'tuple' and "TUPLE" to Python 'tuple'. */
171extern PyObject *RICH_COMPARE_LT_OBJECT_TUPLE_TUPLE(PyObject *operand1, PyObject *operand2);
172
173/* Code referring to "OBJECT" corresponds to any Python object and "TUPLE" to Python 'tuple'. */
174extern nuitka_bool RICH_COMPARE_LT_NBOOL_OBJECT_TUPLE(PyObject *operand1, PyObject *operand2);
175
176/* Code referring to "TUPLE" corresponds to Python 'tuple' and "OBJECT" to any Python object. */
177extern nuitka_bool RICH_COMPARE_LT_NBOOL_TUPLE_OBJECT(PyObject *operand1, PyObject *operand2);
178
179/* Code referring to "TUPLE" corresponds to Python 'tuple' and "TUPLE" to Python 'tuple'. */
180extern nuitka_bool RICH_COMPARE_LT_NBOOL_TUPLE_TUPLE(PyObject *operand1, PyObject *operand2);
181
182/* Code referring to "OBJECT" corresponds to any Python object and "LIST" to Python 'list'. */
183extern PyObject *RICH_COMPARE_LT_OBJECT_OBJECT_LIST(PyObject *operand1, PyObject *operand2);
184
185/* Code referring to "LIST" corresponds to Python 'list' and "OBJECT" to any Python object. */
186extern PyObject *RICH_COMPARE_LT_OBJECT_LIST_OBJECT(PyObject *operand1, PyObject *operand2);
187
188/* Code referring to "LIST" corresponds to Python 'list' and "LIST" to Python 'list'. */
189extern PyObject *RICH_COMPARE_LT_OBJECT_LIST_LIST(PyObject *operand1, PyObject *operand2);
190
191/* Code referring to "OBJECT" corresponds to any Python object and "LIST" to Python 'list'. */
192extern nuitka_bool RICH_COMPARE_LT_NBOOL_OBJECT_LIST(PyObject *operand1, PyObject *operand2);
193
194/* Code referring to "LIST" corresponds to Python 'list' and "OBJECT" to any Python object. */
195extern nuitka_bool RICH_COMPARE_LT_NBOOL_LIST_OBJECT(PyObject *operand1, PyObject *operand2);
196
197/* Code referring to "LIST" corresponds to Python 'list' and "LIST" to Python 'list'. */
198extern nuitka_bool RICH_COMPARE_LT_NBOOL_LIST_LIST(PyObject *operand1, PyObject *operand2);
199
200#if PYTHON_VERSION < 0x300
201/* Code referring to "LONG" corresponds to Python2 'long', Python3 'int' and "INT" to Python2 'int'. */
202extern PyObject *RICH_COMPARE_LT_OBJECT_LONG_INT(PyObject *operand1, PyObject *operand2);
203#endif
204
205#if PYTHON_VERSION < 0x300
206/* Code referring to "LONG" corresponds to Python2 'long', Python3 'int' and "INT" to Python2 'int'. */
207extern bool RICH_COMPARE_LT_CBOOL_LONG_INT(PyObject *operand1, PyObject *operand2);
208#endif
209
210#if PYTHON_VERSION < 0x300
211/* Code referring to "INT" corresponds to Python2 'int' and "CLONG" to C platform long value. */
212extern PyObject *RICH_COMPARE_LT_OBJECT_INT_CLONG(PyObject *operand1, long operand2);
213#endif
214
215#if PYTHON_VERSION < 0x300
216/* Code referring to "INT" corresponds to Python2 'int' and "CLONG" to C platform long value. */
217extern bool RICH_COMPARE_LT_CBOOL_INT_CLONG(PyObject *operand1, long operand2);
218#endif
219
220/* Code referring to "LONG" corresponds to Python2 'long', Python3 'int' and "DIGIT" to C platform digit value for long
221 * Python objects. */
222extern PyObject *RICH_COMPARE_LT_OBJECT_LONG_DIGIT(PyObject *operand1, long operand2);
223
224/* Code referring to "LONG" corresponds to Python2 'long', Python3 'int' and "DIGIT" to C platform digit value for long
225 * Python objects. */
226extern bool RICH_COMPARE_LT_CBOOL_LONG_DIGIT(PyObject *operand1, long operand2);
227
228/* Code referring to "FLOAT" corresponds to Python 'float' and "CFLOAT" to C platform float value. */
229extern PyObject *RICH_COMPARE_LT_OBJECT_FLOAT_CFLOAT(PyObject *operand1, double operand2);
230
231/* Code referring to "FLOAT" corresponds to Python 'float' and "CFLOAT" to C platform float value. */
232extern bool RICH_COMPARE_LT_CBOOL_FLOAT_CFLOAT(PyObject *operand1, double operand2);
233
234// Part of "Nuitka", an optimizing Python compiler that is compatible and
235// integrates with CPython, but also works on its own.
236//
237// Licensed under the Apache License, Version 2.0 (the "License");
238// you may not use this file except in compliance with the License.
239// You may obtain a copy of the License at
240//
241// http://www.apache.org/licenses/LICENSE-2.0
242//
243// Unless required by applicable law or agreed to in writing, software
244// distributed under the License is distributed on an "AS IS" BASIS,
245// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
246// See the License for the specific language governing permissions and
247// limitations under the License.