mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-07-11 04:58:56 +02:00
Updated codegen to work with python3.
Most changes were just replacing usage of "has_key" with "in". Also updated the sorting function which was simplified and changed to a "key" function instead of "cmp" (which is no longer supported in python3. Verified everything builds with python 2.7 and 3. https://bugzilla.gnome.org/show_bug.cgi?id=678066
This commit is contained in:
committed by
Colin Walters
parent
6d5484b296
commit
03611f7c06
@ -184,8 +184,8 @@ def codegen_main():
|
||||
|
||||
c_code = opts.generate_c_code
|
||||
if c_code:
|
||||
h = file(c_code + '.h', 'w')
|
||||
c = file(c_code + '.c', 'w')
|
||||
h = open(c_code + '.h', 'w')
|
||||
c = open(c_code + '.c', 'w')
|
||||
gen = codegen.CodeGenerator(all_ifaces,
|
||||
opts.c_namespace,
|
||||
opts.interface_prefix,
|
||||
|
Reference in New Issue
Block a user