File indexing completed on 2024-05-19 04:42:03

0001 #!/usr/bin/env python3
0002 # -*- coding: utf-8 -*-
0003 #
0004 # SPDX-FileCopyrightText: 2014 Denis Steckelmacher <steckdenis@yahoo.fr>
0005 #
0006 # SPDX-License-Identifier: GPL-2.0-only OR GPL-3.0-only OR LicenseRef-KDE-Accepted-GPL
0007 
0008 # Print the license of the generated file (the same as the one of this file)
0009 def license():
0010     print("""/*
0011     SPDX-FileCopyrightText: 2014 Denis Steckelmacher <steckdenis@yahoo.fr>
0012 
0013     SPDX-License-Identifier: GPL-2.0-only OR GPL-3.0-only OR LicenseRef-KDE-Accepted-GPL
0014 */
0015 """)
0016 
0017 def basicTypes(d):
0018     d["_mixed"] = '_mixed'       # This variable does not exist and will therefore yield the type "mixed"
0019     d["_string"] = '""'
0020     d["_bool"] = 'true'
0021     d["_int"] = '1'
0022     d["_float"] = '1.0'
0023     d["_array"] = '[]'
0024     d["_void"] = ''
0025 
0026 def require(module):
0027     print('var %s = require("%s");\n' % (module, module))