diff options
author | Jasper St. Pierre <jstpierre@mecheye.net> | 2013-02-18 16:28:36 -0500 |
---|---|---|
committer | Jasper St. Pierre <jstpierre@mecheye.net> | 2013-02-18 16:30:56 -0500 |
commit | 1c57d575d195428a2cbaa4137095a3bffbd4c88f (patch) | |
tree | 2b6c470f3d2e3646f1affb4211e87824cae94b43 /giscanner/sourcescanner.c | |
parent | 5aa1e8c8cb1d8dee3c214235634539ccd7eda8fe (diff) | |
download | gobject-introspection-1c57d575d195428a2cbaa4137095a3bffbd4c88f.tar.gz |
sourcescanner: Make sure to mark constants as set
This fixes complex constants.
Diffstat (limited to 'giscanner/sourcescanner.c')
-rw-r--r-- | giscanner/sourcescanner.c | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/giscanner/sourcescanner.c b/giscanner/sourcescanner.c index c14c3449..7ee0536c 100644 --- a/giscanner/sourcescanner.c +++ b/giscanner/sourcescanner.c @@ -54,12 +54,16 @@ gi_source_symbol_copy (GISourceSymbol * symbol) if (symbol->base_type) new_symbol->base_type = gi_source_type_copy (symbol->base_type); - if (symbol->const_int_set) + + if (symbol->const_int_set) { new_symbol->const_int = symbol->const_int; - else if (symbol->const_double_set) + new_symbol->const_int_set = TRUE; + } else if (symbol->const_double_set) { new_symbol->const_double = symbol->const_double; - else if (symbol->const_string != NULL) + new_symbol->const_double_set = TRUE; + } else if (symbol->const_string != NULL) { new_symbol->const_string = g_strdup (symbol->const_string); + } return new_symbol; } |