summaryrefslogtreecommitdiff
path: root/giscanner
Commit message (Collapse)AuthorAgeFilesLines
* Fix marshalling of GStrv.GOBJECT_INTROSPECTION_0_6_13Tomeu Vizoso2010-06-022-2/+9
| | | | | | | | | | | | | | | | | | * gir/gimarshallingtests.[hc]: Add a test for GStrv in function args and as struct fields. * girepository/giroffsets.c: Correctly compute the size of structs with array fields * girepository/girparser.c: Set is_pointer to FALSE for arrays with fixed size that are inside structs. * giscanner/glibtransformer.py: Special case GStrv as arrays of utf8. * giscanner/annotationparser.py: Make full transfer the default for arrays of char* returned by functions. https://bugzilla.gnome.org/show_bug.cgi?id=620170
* [giscanner] Parse multiline gtk-doc commentsJohan Dahlin2010-05-311-2/+10
|
* [build] Remove gcov supportJohan Dahlin2010-05-281-4/+0
| | | | | It's been broken for some time, remove it instead of letting it bitrot.
* Add type annotation for propertiesJohan Dahlin2010-05-271-0/+4
| | | | | | | | | | Add type annotation syntax for GObject properties. This makes it possible to override the type of a property. For instance, this will allow function pointers with a G_TYPE_POINTER type set to be used from a language binding which reads the typelib information in addition g_object_class_find_property. https://bugzilla.gnome.org/show_bug.cgi?id=618318
* [scanner] Element-type annotation for GArray typesJohan Dahlin2010-05-271-4/+13
| | | | | | | Add support for (element-type) annotations for G*Array types. https://bugzilla.gnome.org/show_bug.cgi?id=619545
* [annotationparser] Avoid a couple of \Johan Dahlin2010-05-271-3/+3
|
* Support (out caller-allocates)Colin Walters2010-05-263-2/+25
| | | | | | | | | | | | | | | | | | | | | People have wanted support for marking (out) on functions of the form: /** * clutter_color_from_pixel: * @pixel: A pixel * @color: (out): Color to initialize with value of @pixel */ void clutter_color_from_pixel (guint32 pixel, ClutterColor *color); Where the caller is supposed to have allocated the argument; the C function just initializes it. This patch adds support for this argument passing style to introspection. In this case, we see the (out), and notice that there's only a single indirection (*) on the argument, and assume that this means (out caller-allocates). https://bugzilla.gnome.org/show_bug.cgi?id=604749
* [scanner] Support unsigned long/short intAlan Knowles2010-05-251-0/+2
|
* [sourcescanner] Support for line numbers on SymbolAlan Knowles2010-05-254-54/+64
| | | | | Add line numbers to symbols, which can be useful in later stages of the scanner.
* Add support for the 'foreign' annotation to g-i-scannerGOBJECT_INTROSPECTION_0_6_12Tomeu Vizoso2010-05-233-0/+10
| | | | https://bugzilla.gnome.org/show_bug.cgi?id=619450
* Take into account the underscore after the type name when checking if a ↵Tomeu Vizoso2010-05-191-1/+1
| | | | | | function is a method https://bugzilla.gnome.org/show_bug.cgi?id=617876
* Add uid_t, gid_t, dev_t to integral type conversionsColin Walters2010-05-191-3/+19
| | | | | | | | Continuing where we were going with pid_t, define a few more POSIX types by converting them to their fundamental integers. See commentary in patch for more explanation on rationale. https://bugzilla.gnome.org/show_bug.cgi?id=618778
* Fix parameter ordering in error messageOwen W. Taylor2010-05-071-1/+1
| | | | | The function name and parameter name were backwards when warning about bad parameter references.
* Validate parameter referencesOwen W. Taylor2010-05-071-3/+20
| | | | | | | | | | | When an annotation references another parameter, check that that parameter actually exists. Add a comment to the handling of (closure) for callbacks to explain why we don't need the same handling there despite the use of get_parameter_index(). https://bugzilla.gnome.org/show_bug.cgi?id=617978
* Validate scope annotation valuesOwen W. Taylor2010-05-072-0/+14
| | | | | | | Make sure that the value specified for scope in a callback annotation is one of the legal values. https://bugzilla.gnome.org/show_bug.cgi?id=617978
* Use -1 not None for closure/destroy indicesOwen W. Taylor2010-05-071-2/+2
| | | | | | | Don't assign None to closure and destroy indices in case of collision, they are supposed to be numeric. https://bugzilla.gnome.org/show_bug.cgi?id=617978
* Add support for GArrays: add g_type_info_get_array_type() and properly scan ↵Tomeu Vizoso2010-05-045-8/+44
| | | | | | | | GArray args Based on a previous patch by C. Scott Ananian <cscott@litl.com> https://bugzilla.gnome.org/show_bug.cgi?id=581687
* Revert "Add support for GArrays: add g_type_info_get_array_type() and ↵Tomeu Vizoso2010-05-031-6/+0
| | | | | | properly scan GArray args" This reverts commit 87291e08b0fd34b62e1ad9811c174108b38311a9.
* Add support for GArrays: add g_type_info_get_array_type() and properly scan ↵Tomeu Vizoso2010-04-301-0/+6
| | | | | | | | GArray args Based on a previous patch by C. Scott Ananian <cscott@litl.com> https://bugzilla.gnome.org/show_bug.cgi?id=581687
* [annotationparser] Disable warningJohan Dahlin2010-04-281-2/+3
|
* Warn about annotations for unknown argsTomeu Vizoso2010-04-281-0/+14
| | | | https://bugzilla.gnome.org/show_bug.cgi?id=615890
* If needed, convert from camelcase to underscores when stripping the prefix ↵Tomeu Vizoso2010-04-141-1/+1
| | | | | | of constants https://bugzilla.gnome.org/show_bug.cgi?id=615694
* Small fix to handle @attributes: .... (.....) as a parameter to a functionAlan Knowles2010-03-151-1/+2
| | | | Previously crashed out, now just ignores the attribute
* [giscanner] Catch CalledProcessError and OSErrorJohan Dahlin2010-02-171-1/+1
| | | | | Instead of catching all errors, including AttributeError, TypeError and NameError.
* [scanner] Catch OSError too when checking for libtoolColin Walters2010-02-171-1/+1
| | | | | | If we don't have permission to execute the libtool binary, we'd just throw here which is wrong. Fix this by catching all exceptions.
* Fix glib:error-quark scanning for unregistered enum typesOwen W. Taylor2010-02-123-9/+43
| | | | | | | | | | | | The enumeration type for an error might not be introspected and registered with GObject (this is, in particular, true for the errors in GLib itself). So, as a fallback search, through all enum types in the module. Add a special case for the aberrant GIOErrorEnum and a warning if resolution completely fails. https://bugzilla.gnome.org/show_bug.cgi?id=602512
* Assume allow-none for GCancellableColin Walters2010-02-111-2/+4
| | | | | | | All GCancellables are allow-none, this allows us to remove a lot of custom annotations. https://bugzilla.gnome.org/show_bug.cgi?id=604658
* Conform last patch with pep8Colin Walters2010-02-111-1/+2
|
* [scanner] Print error instead of throwing for unknown includeColin Walters2010-02-112-3/+8
| | | | We should avoid exceptions being propagated to the toplevel.
* scanner: Always explicitely set the scope of callbacksJohan Bilien2010-01-142-1/+5
| | | | | | default to 'call' as stated in the annotation documentation. https://bugzilla.gnome.org/show_bug.cgi?id=607026
* Don't remove .c file for dumper binaryOwen W. Taylor2010-01-121-2/+0
| | | | | | | | | We're going to remove the entire temporary directory, so there's no point in explicitly removing just the .c file we create; leaving the .c file behind makes it easier to debug problems. https://bugzilla.gnome.org/show_bug.cgi?id=605966
* Remove tabs, fixes make checkJohan Dahlin2010-01-081-4/+4
|
* Add an --add-init-section argumentDamien Lespiau2010-01-052-5/+15
| | | | | | | | | | One might need to call some init functions before being able to call get_type() to create the types of a library. --add-init-section let the user insert some initialization code in the introspection program. https://bugzilla.gnome.org/show_bug.cgi?id=605778
* __extension__ can be put in front of expressionsDamien Lespiau2009-12-311-0/+1
| | | | | | | | | | | | glib uses __extension__ in macros dealing with 64 bits integer such as GUINT64_SWAP_LE_BE(). To quote the GCC manual: `-pedantic' and other options cause warnings for many GNU C extensions. You can prevent such warnings within one expression by writing `__extension__' before the expression. https://bugzilla.gnome.org/show_bug.cgi?id=605779
* Fix typo in the help string of the --no-libtool argumentDamien Lespiau2009-12-311-1/+1
| | | | | | | --no-libtool means that one does not want to use libtool to compile the introspection program. https://bugzilla.gnome.org/show_bug.cgi?id=605774
* Include Python.h earlierJohan Dahlin2009-12-311-1/+1
| | | | This avoids pyconfig.h:1028:1: warning: "_POSIX_C_SOURCE" redefined
* [scanner] Fix various hardcoded type name checksDan Winship2009-12-093-12/+16
| | | | | | | | Various places that check hardcoded type names were not always handling the case of the type being used from within its own library (in which case it won't have a type prefix). Make them more consistent. https://bugzilla.gnome.org/show_bug.cgi?id=602512
* [scanner] "GError *" is not the same as "GError **"Dan Winship2009-12-091-3/+3
| | | | | | Only set "throws" in the latter case https://bugzilla.gnome.org/show_bug.cgi?id=602512
* Fix an annotationparser bug for empty tagsJohan Dahlin2009-12-091-0/+2
| | | | | | Makes sure we can parse empty tags such as '@foo:' without adding a : in the end which the typelib compiler will complain about
* Wrap line in 80 charactersJohan Dahlin2009-12-081-2/+3
|
* [transformer] Look up callback types in the full name set, not just typedefsColin Walters2009-12-081-2/+4
| | | | When looking up GINames, we should look in _names.names.
* scanner: more verbose parser error messagesStefan Kost2009-12-052-3/+10
| | | | | Keep track of the current line (the first 2000 chars of it) and include that in syntax error messages. Also print that failed token in the error message.
* scanner: fix wrong linenumbers in parser errorsStefan Kost2009-12-051-0/+3
| | | | Increment linenumber in parse_comment which reads over multiline comments.
* annotationparser: include symbol name in warningStefan Kost2009-12-041-2/+2
| | | | | Telling file and line would be better, but alreday this way one atleast has a chance to fix it actually.
* scanner: don't warn about unexpected characters when the char is \0Stefan Kost2009-12-041-1/+1
|
* Check for AsyncReadyCallback / DestroyNotifyJohan Dahlin2009-12-031-2/+3
| | | | | This should have been included with f74823. Fixes the async/notified scope annotation for glib/gio.
* [dumper] Fix threads initializationColin Walters2009-12-021-1/+1
| | | | | Correctly guard with g_thread_supported, call g_thread_init before g_type_init.
* Ignore errors caused by permissions in $HOMEJosselin Mouette2009-12-021-1/+4
| | | | https://bugzilla.gnome.org/show_bug.cgi?id=596960
* Better scope in GAsyncReadyCallback/GDestroyNotifyJohan Dahlin2009-12-021-1/+18
| | | | | | | | GAsyncReadyCallback should have use the async scope per default and GDestroyNotify should be notified if the previous parameters are a callback and user data. Fixes https://bugzilla.gnome.org/show_bug.cgi?id=602862
* InitiallyUnownedClass should contain all the fields as ObjectClass if we ↵Tomeu Vizoso2009-11-301-0/+2
| | | | | | want offset counting to be correct in its sublasses https://bugzilla.gnome.org/show_bug.cgi?id=603038