Bug 563469 – Arrays not treated correctly in struct offset calculation
[gnome.gobject-introspection] / ChangeLog
1 2009-02-02  Andreas Rottmann  <a.rottmann@gmx.at>
2
3         Bug 563469 – Arrays not treated correctly in struct offset calculation
4
5         * tests/offsets/offsets.h (OffsetsArray): New struct, containing a
6         bunch of arrays.
7
8         * tests/offsets/gen-gitestoffsets (FIELD_RE): Handle arrays.
9
10         * girepository/giroffsets.c (get_interface_size_alignment):
11         Refactored to make it more general, now takes a GIrNodeType*
12         instead of a GIrNodeField*, plus an additional 'who' parameter
13         that denotes what the size/alignment is calculated for.
14         (get_type_size_alignment): New function, refactored version of
15         get_field_size_alignment().
16         (get_field_size_alignment): Implemented in terms of
17         get_type_size_alignment().
18         (get_type_size_alignment): Handle array types correctly.
19
20   2009-01-28  Johan Bilien  <jobi@via.ecp.fr>
21
22         * tests/scanner/annotation-1.0-expected.gir: add missing
23         with_voidp
24
25 2009-01-27  Johan Dahlin  <jdahlin@async.com.br>
26
27         * gir/cairo-1.0.gir:
28         * gir/fontconfig-2.0.gir:
29         * gir/freetype2-2.0.gir:
30         * gir/libxml2-2.0.gir:
31         * gir/xfixes-4.0.gir:
32         * gir/xft-2.0.gir:
33         * gir/xlib-2.0.gir:
34         Remove shared-library tags for these too.
35
36 2009-01-27  Johan Dahlin  <jdahlin@async.com.br>
37
38         * gir/GL-1.0.gir:
39         Remove shared-library which removes the build
40         time dependency on mesa.
41
42 2009-01-27  Dan Winship  <danw@gnome.org>
43
44         Misc warning fixes
45
46         * giscanner/scannerparser.y: Fix the "Ignoring non-UTF-8 constant
47         string" error to print the right value.
48
49         * tests/scanner/annotation.c (backslash_parsing_tester)
50         (backslash_parsing_tester_2): make these non-static to avoid a
51         warning.
52         (annotation_object_string_out)
53         (annotation_string_zero_terminated): fix return values
54
55         * tests/scanner/annotation.h (annotation_object_with_voidp):
56         prototype this
57
58         * tests/scanner/gtkfrob.c:
59         * tests/scanner/gtkfrob.h (gtk_frob_language_manager_get_default):
60         fix prototype. (s/()/(void)/).
61
62         * tools/compiler.c (format_output): fix signed/unsigned warning.
63         Output a prototype for register_typelib() to avoid warnings later.
64
65 2009-01-26  Johan Dahlin  <jdahlin@async.com.br>
66
67         * tests/everything/everything.c (test_callback):
68         * tests/everything/everything.h:
69         Add a couple of callback tests.
70
71 2009-01-26  Johan Dahlin  <jdahlin@async.com.br>
72
73         * girepository/ginfo.c (g_base_info_unref):
74         Only unref the repository if it's actually set.
75
76 2009-01-23  Johan Dahlin  <jdahlin@async.com.br>
77
78         * tests/everything/everything.c (test_enum_param):
79         * tests/everything/everything.h:
80
81         Add an enum param test function
82
83 2009-01-21  Johan Dahlin  <jdahlin@async.com.br>
84
85         * configure.ac:
86         Post-release version bump
87
88 === 0.6.2 ===
89 2009-01-21  Johan Dahlin  <jdahlin@async.com.br>
90
91         * NEWS: Update
92
93 2009-01-21  Johan Dahlin  <jdahlin@async.com.br>
94
95         Bug 562622 – Errordomains missing
96
97         * giscanner/girwriter.py:
98         * giscanner/glibast.py:
99         * giscanner/glibtransformer.py:
100         * tests/scanner/Makefile.am:
101         * tests/scanner/foo-1.0-expected.gir:
102         * tests/scanner/foo-1.0-expected.tgir:
103         * tests/scanner/foo.c (foo_error_get_type), (foo_error_quark):
104         * tests/scanner/foo.h:
105
106 2009-01-20  Johan Dahlin  <jdahlin@async.com.br>
107
108         * giscanner/scannerlexer.l:
109         Increase the buffer size to 1M, so
110         gtkalias.h can be parsed.
111
112 2009-01-20  Johan Dahlin  <jdahlin@async.com.br>
113
114         * giscanner/glibtransformer.py:
115         When trying to map functions to structs, do
116         not require a public structure to exist, should
117         fix Gst gir generation in.
118
119 2009-01-20  Johan Dahlin  <jdahlin@async.com.br>
120
121         Bug 562615 – Struct methods missing
122
123         * giscanner/annotationparser.py:
124         * giscanner/ast.py:
125         * giscanner/girwriter.py:
126         * giscanner/glibast.py:
127         * giscanner/glibtransformer.py:
128         * tests/scanner/foo-1.0-expected.gir:
129         * tests/scanner/foo-1.0-expected.tgir:
130
131 2009-01-16  Dan Winship  <danw@gnome.org>
132
133         * gir/GL-1.0.gir: add back GLvoid, which got lost during the
134         gir-repository -> gobject-introspection migration
135
136 2009-01-15  Johan Dahlin  <jdahlin@async.com.br>
137
138         * gir/freetype2-2.0.gir: add FT_Int32
139         * gir/xft-2.0.gir: add XftFont
140         * girepository/gdump.c (g_irepository_dump):
141         Report errors when an invalid type is encountered
142         * giscanner/glibtransformer.py:
143         Make the error message a bit nicer.
144
145         Part of preparating for gir generating inside pango.
146
147 2009-01-15  Johan Dahlin  <jdahlin@async.com.br>
148
149         * gir/GL-1.0.gir:
150         * gir/Makefile.am:
151         * gir/cairo-1.0.gir:
152         * gir/fontconfig-2.0.gir:
153         * gir/freetype2-2.0.gir:
154         * gir/libxml2-2.0.gir:
155         * gir/xfixes-4.0.gir:
156         * gir/xft-2.0.gir:
157         * gir/xlib-2.0.gir:
158
159         Move over the hand-written girs from gir-repository
160         so upstream libraries depending on these can avoid
161         a gir-repository dependency.
162
163 2009-01-15  Johan Dahlin  <jdahlin@async.com.br>
164
165         Bug 567813 – Everything should be versioned
166
167         * gir/Makefile.am:
168         * girepository/Makefile.am:
169         * girepository/girepository.c (init_globals):
170         * girepository/girparser.c (locate_gir):
171         * giscanner/dumper.py:
172         * giscanner/transformer.py:
173         * gobject-introspection-1.0.pc.in:
174         * tests/everything/Makefile.am:
175         * tests/invoke/Makefile.am:
176         * tests/offsets/Makefile.am:
177         * tests/repository/Makefile.am:
178         * tests/scanner/Makefile.am:
179         * tools/Makefile.am:
180
181 2009-01-13  Johan Dahlin  <jdahlin@async.com.br>
182
183         Bug 555036 – put gtk-doc in GIR
184
185         * giscanner/annotationparser.py:
186         * giscanner/ast.py:
187         * giscanner/girwriter.py:
188         * giscanner/glibast.py:
189         * tests/scanner/annotation-1.0-expected.gir:
190         * tests/scanner/annotation.h:
191         * tests/scanner/foo-1.0-expected.gir:
192
193 2009-01-13  Johan Dahlin  <jdahlin@async.com.br>
194
195         * giscanner/cachestore.py (CacheStore.load): Catch AttributeError
196         which seems to be occasionally raised for Record.
197
198         * giscanner/annotationparser.py:
199         Fix a bug where \n was not present in a comment
200
201 2009-01-12  Johan Dahlin  <jdahlin@async.com.br>
202
203         Bug 562467 – Property annotation
204
205         * giscanner/annotationparser.py:
206         * tests/scanner/annotation-1.0-expected.gir:
207         * tests/scanner/annotation-1.0-expected.tgir:
208         * tests/scanner/annotation.c (annotation_object_set_property),
209         (annotation_object_get_property), (annotation_object_class_init):
210
211         Annotations are parsed for properties.
212
213 2009-01-12  Johan Dahlin  <jdahlin@async.com.br>
214
215         Bug 546739 – Introspection should know precise signal parameter types
216
217         * giscanner/annotationparser.py:
218         * tests/scanner/annotation-1.0-expected.gir:
219         * tests/scanner/annotation-1.0-expected.tgir:
220         * tests/scanner/annotation.c (annotation_object_class_init):
221
222         Annotations are parsed for signals, the (type) annotation is introduced.
223
224 2009-01-12  Johan Dahlin  <jdahlin@async.com.br>
225
226         Bug 563591 – Flags not recognized when there is no introspection data
227
228         * giscanner/ast.py:
229         * giscanner/girwriter.py:
230         * giscanner/giscannermodule.c (type_get_is_bitfield):
231         * giscanner/glibast.py:
232         * giscanner/glibtransformer.py:
233         * giscanner/scannerparser.y:
234         * giscanner/sourcescanner.c (gi_source_type_copy):
235         * giscanner/sourcescanner.h:
236         * giscanner/sourcescanner.py:
237         * giscanner/transformer.py:
238         * tests/scanner/foo-1.0-expected.gir:
239         * tests/scanner/foo-1.0-expected.tgir:
240         * tests/scanner/foo.h:
241
242         Large parts of this patch was done by Jürg Billeter.
243
244 2009-01-12  Havoc Pennington  <hp@pobox.com>
245
246         Bug 563386 – scanner ignores "const" on boxed return values
247
248         * tests/everything/everything.c (test_simple_boxed_a_const_return):
249         * tests/everything/everything.h:
250
251         This adds just the tests specified in the bug above, the fix itself
252         was included in Bug 563794
253
254 2009-01-03  Andreas Rottmann  <a.rottmann@gmx.at>
255
256         Bug 566404 – Annotations for GLib
257
258         * gir/glib-2.0.c: Added allow-none annotations for g_thread_init()
259         and g_main_loop_new().
260
261 2009-01-12  Johan Dahlin  <jdahlin@async.com.br>
262
263         Bug 566419 – Element type of arrays not properly handled in all cases
264
265         * giscanner/annotationparser.py:
266         * tests/scanner/annotation-1.0-expected.gir:
267         * tests/scanner/annotation-1.0-expected.tgir:
268         * tests/scanner/annotation.c (annotation_object_set_data),
269         (annotation_object_set_data2), (annotation_object_set_data3):
270         * tests/scanner/annotation.h:
271
272         Based on patch by Andreas Rottmann
273
274 2009-01-12  Johan Dahlin  <jdahlin@async.com.br>
275
276         Bug 566560 – giscanner.transformer.SkipError
277
278         * giscanner/transformer.py:
279
280         Catch SkipError for all nodes, not just functions.
281         Makes it possible to skip unsupported parameter types in 
282         callbacks.
283
284 2009-01-12  Johan Dahlin  <jdahlin@async.com.br>
285
286         Bug 563794 - Redo annotation parsing & applying
287         
288         Thanks to Colin for helping out considerably in landing this.
289
290         * giscanner/Makefile.am:
291         * giscanner/ast.py:
292         * giscanner/dumper.py:
293         * giscanner/girparser.py:
294         * giscanner/giscannermodule.c (pygi_source_scanner_get_comments),
295         (calc_attrs_length), (pygi_collect_attributes), (init_giscanner):
296         * giscanner/glibtransformer.py:
297         * giscanner/scannerlexer.l:
298         * giscanner/sourcescanner.c (gi_source_symbol_unref),
299         (gi_source_scanner_new), (gi_source_scanner_free),
300         (gi_source_scanner_get_comments):
301         * giscanner/sourcescanner.h:
302         * giscanner/sourcescanner.py:
303         * giscanner/transformer.py:
304         * giscanner/xmlwriter.py:
305         * tests/scanner/annotation-1.0-expected.gir:
306         * tests/scanner/annotation-1.0-expected.tgir:
307         * tests/scanner/annotation.c:
308         * tests/scanner/annotation.h:
309         * tests/scanner/foo-1.0-expected.gir:
310         * tests/scanner/foo-1.0-expected.tgir:
311         * tests/scanner/foo.h:
312         * tools/g-ir-scanner:
313
314         This commit merges the annotation parser rewrite branch.
315         It'll change the annotation parsing to be done completely in python
316         code which will make it easier to do further annotation parsing 
317         easier.
318
319 2009-01-03  Andreas Rottmann  <a.rottmann@gmx.at>
320  
321         Bug 563469 – Arrays not treated correctly in struct offset calculation
322         
323         * tests/scanner/foo.h (FooObject): Added field `some_int'.
324         * tests/scanner/foo-1.0-expected.gir,
325         * tests/scanner/foo-1.0-expected.tgir: Adapted.
326  
327         * giscanner/glibtransformer.py (GLibTransformer._create_gobject):
328         carry over object fields from original (struct) node.
329         (GLibTransformer._pair_class_struct): Don't add fields of the
330         class struct to to the node for the class, they should go under a
331         nested <record> element (see also Bug 551738). This is needed as
332         otherwise offset calculation would not work, as the instance
333         fields are mingled with the class fields without a way to
334         distinguish them.
335   
336 2009-01-03  Johan Dahlin  <jdahlin@async.com.br>
337
338         * misc/pep8.py:
339         Disable blank line check, it works differently under
340         Python 2.5 from 2.6 and was rather annoying from the start.
341
342 2008-01-03  Andreas Rottmann  <a.rottmann@gmx.at>
343
344         Bug 556489 – callback annotations
345         
346         * giscanner/transformer.py 
347
348         * tools/generate.c (write_callable_info): Write out the new scope,
349         closure and destroy attributes.
350
351         * giscanner/transformer.py (Transformer._type_is_callback): New
352         method, checking if a given type is a callback.
353         (Transformer._augment_callback_params): New method; adds
354         information (closure, destroy) to callback parameters.
355         (Transformer._handle_closure, Transformer._handle_destroy): New methods, 
356         auxiliary to _augment_callback_params.
357         (Transformer._create_function): Call _augment_callback_params().
358         (Transformer._create_parameter): Handle scope option.
359
360         (Transformer._create_typedef_callback): New method, creates a
361         callback, and registers it in the typedef namespace
362         (Transformer._create_typedef): Use _create_typedef_callback()
363         instead of the plain _create_callback().
364
365         * giscanner/ast.py (Parameter): Added callback-related fields.
366         * giscanner/girwriter.py: Write out new Parameter fields.
367
368         * girepository/girnode.h (GIrNodeParam): Added fields scope, 
369         closure and destroy.
370         * girepository/gtypelib.h (ArgBlob): Ditto.
371         * girepository/girparser.c (start_parameter): Handle new fields.
372
373         * girepository/girmodule.c (g_ir_module_build_typelib): Adjust
374         arg_blob_size, bump major version due to this change.
375         * girepository/girnode.c (g_ir_node_get_full_size_internal)
376         (g_ir_node_build_typelib)
377         * girepository/gtypelib.c (g_typelib_check_sanity): ArgBlob size
378         adjustments.
379         (g_ir_node_build_typelib): Fill in new ArgBlob flags from param. 
380
381         * girepository/girepository.h (GIScope): New enumeration, listing
382         the different possible scopes for callbacks.
383
384         * girepository/ginfo.c (g_arg_info_get_scope)
385         (g_arg_info_get_closure, g_arg_info_get_destroy): Accessors for
386         callback-related argument indices (callback scope, closure for a
387         callback, destroy notification for a callback).
388
389         * tests/scanner/: Added testcases for new features.
390         
391 2009-01-03  Jürg Billeter  <j@bitron.ch>
392
393         * giscanner/ast.py:
394         * giscanner/dumper.py:
395         * giscanner/girparser.py:
396         * giscanner/glibtransformer.py:
397         * giscanner/sourcescanner.py:
398         * giscanner/transformer.py:
399         * giscanner/xmlwriter.py:
400
401         Fix inconsistencies with PEP8
402
403 2008-12-21  Johan Dahlin  <jdahlin@async.com.br>
404
405         * gir/gio-2.0.c:
406         Annotate transfer, direction and allow none for
407         g_file_load_contents, g_file_load_contents_finish and
408         g_file_load_partial_contents_finish parameters.
409
410 2008-12-12  Owen Taylor  <otaylor@redhat.com>
411
412         Disable array auto-detection for out-annotated parameters (#563934)
413
414         If we have a parameter annotated as (out), then having a ctype of
415         'char **' (or similar) doesn't necessarily indicate an array.
416
417         * giscanner/transformer.py: Skip array-detection logic for
418         (out)-annotated parameters.
419         * tests/scanner/annotation.h tests/scanner/annotation.c
420         tests/scanner/annotation-1.0-expected.gir
421         tests/scanner/annotation-1.0-expected.tgir: Add a test for
422         an (out) string parameter.
423
424 2008-12-12  Johan Dahlin  <jdahlin@async.com.br>
425
426         * giscanner/dumper.py (DumpCompiler._link): Pass in
427         --tag=CC to libtool to avoid making libtool confused
428         when CC is different from gcc on some systems.
429
430 2008-12-10  Johan Bilien  <jobi@via.ecp.fr>
431
432         Bug 563998 – Cache the GIBaseInfo for GTypes
433
434         * girepository/girepository.c (g_irepository_find_by_gtype):
435         add a cache of GType -> GIBaseInfo.
436
437 2008-12-09  Johan Bilien  <jobi@via.ecp.fr>
438
439         Bug 562545 – Add function taking / returning GValue
440
441         * tests/everything/everything.[ch]: add a test of function taking and
442         returning "const GValue *"
443
444 2008-12-09  Johan Dahlin  <johan@async.com.br>
445
446         * giscanner/cachestore.py (CacheStore.store): Use
447         shutil.move instead of os.rename, since it will
448         automatically fall back to copying+remove if the
449         src directory is on a different partition from
450         the dst directory.
451
452 2008-12-08  Tristan Van Berkom  <tristan.van.berkom@gmail.com>
453
454         Bug 563742 – introspection should record the introduced version of
455                      symbols marked with the "Since:" tag
456
457         reviewed by: Johan
458
459         * giscanner/ast.py:
460         * giscanner/girwriter.py:
461         * giscanner/scannerlexer.l:
462         * giscanner/transformer.py:
463         * tests/scanner/annotation-1.0-expected.gir:
464         * tests/scanner/annotation-1.0-expected.tgir:
465         * tests/scanner/annotation.c (annotation_versioned):
466         * tests/scanner/annotation.h:
467
468 2008-12-08  Johan Dahlin  <johan@async.com.br>
469
470         * giscanner/cachestore.py (_get_cachedir): Don't require
471         HOME to be set and if it set, don't require the
472         directory to exist.
473
474 2008-12-08  Johan Dahlin  <johan@async.com.br>
475
476         * giscanner/cachestore.py (CacheStore.store): Dump the cache
477         file to a temporary file and rename it the expected filename
478         only when it's completely written.
479         This should make the cache more roboust when run in parallel,
480         and hopefully avoid triggering bugs in Python.
481
482 2008-12-03  Christophe Fergeau  <teuf@gnome.org>
483
484         Bug 562971 – g-ir-scanner failure on libgpod headers
485
486         * giscanner/scannerlexer.l: raise YY_BUF_SIZE to 65536 up from the
487         default 16384. Without it, the lexer was aborting with a cryptic
488         error message on source files containing really long comment
489         blocks.
490
491 2008-12-01  Colin Walters  <walters@verbum.org>
492
493         * girepository/gfield.c: Fix memory leak; unref type info we
494         created, not field info
495
496 2008-11-30  Johan Dahlin  <jdahlin@async.com.br>
497
498         Bug 562289 – Race when removing invalid cache
499
500         * giscanner/cachestore.py:
501         ENOENT is mapped to a OSError, not IOError.
502
503 2008-11-27  Johan Dahlin  <jdahlin@async.com.br>
504
505         * gir/glib-2.0.c: Add return value transfer annotation
506         for g_markup_escape_text.
507
508 2008-11-25  Colin Walters  <walters@verbum.org>
509
510         * tools/g-ir-scanner: Add --libtool option which we expect Automake-using
511         people to pass.
512         * giscanner/dumper.py: Implement it.
513         * gir/Makefile.am, tests/**/Makefile.am: Use it.
514
515 2008-11-25  Colin Walters  <walters@verbum.org>
516
517         * tests/scanner/Makefile.am: Remove hand-rolled generation of .tgir; easier
518         to just use a Makefile rule and dependencies.  This corresponds with a change
519         made to gir-repository to fix srcdir != builddir issues.
520
521 2008-11-25  Johan Dahlin  <jdahlin@async.com.br>
522
523         * configure.ac:
524         Post release version bump
525
526 === 0.6.1 ===
527 2008-11-25  Johan Dahlin  <jdahlin@async.com.br>
528
529         * NEWS:
530         Release 0.6.1
531
532 2008-11-25  Colin Walters  <walters@verbum.org>
533
534         Bug 559705 – Missing association between static methods and classes
535
536         * docs/typelib-format.txt:
537         * girepository/ginfo.c (g_function_info_get_flags):
538         * girepository/girmodule.c (g_ir_module_build_typelib):
539         * girepository/girnode.c (g_ir_node_get_size),
540         (g_ir_node_build_typelib):
541         * girepository/girparser.c (start_function):
542         * girepository/gtypelib.c (g_typelib_check_sanity),
543         (validate_header), (validate_function_blob):
544         * girepository/gtypelib.h:
545         * giscanner/ast.py:
546         * giscanner/girwriter.py:
547         * giscanner/glibtransformer.py:
548         * tests/scanner/foo-1.0-expected.gir:
549         * tests/scanner/foo-1.0-expected.tgir:
550         * tests/scanner/foo.h:
551
552 2008-11-25  Johan Dahlin  <jdahlin@async.com.br>
553
554         * giscanner/ast.py: Define socklen_t as an alias for int32.
555
556 2008-11-24  Johan Dahlin  <jdahlin@async.com.br>
557
558         * girepository/gdump.c (dump_type): Remove a warning,
559         be less verbose on error on fundamental types.
560
561 2008-11-23  Johan Dahlin  <jdahlin@async.com.br>
562
563         * giscanner/dumper.py: Add license headers,
564         refactor into a class, avoid some duplication and do some
565         extra pedantic checks.
566
567 2008-11-23  Johan Dahlin  <jdahlin@async.com.br>
568
569         Make it compilable with -Werror on my system by adding
570         a couple of prototypes and including headers.
571
572 2008-11-23  Johan Dahlin  <jdahlin@async.com.br>
573
574         Bug 562022 – gobject-introspection needs python headers
575
576         * configure.ac: fail without python headers present.
577         Patch by: Tom Parker
578
579 2008-11-21  Johan Dahlin  <jdahlin@async.com.br>
580
581         Bug 561617 – Return value array annotations
582
583         * giscanner/transformer.py:
584         * tests/scanner/annotation.c (annotation_return_array):
585         * tests/scanner/annotation.h:
586         Add support for (array) for return value annotations as well.
587
588 2008-11-20  Johan Bilien  <jobi@via.ecp.fr>
589
590         * tests/everything/everything.[ch]: add a test function which calls a
591         closure.
592
593 2008-11-19  Johan Dahlin  <jdahlin@async.com.br>
594
595         * giscanner/cachestore.py:
596         Catch ValueError exceptions.
597
598 2008-11-18  Tommi Komulainen  <tommi.komulainen@iki.fi>
599
600         * tests/scanner/Makefile.am (barapp_SOURCES): fix builddir != srcdir
601
602 2008-11-18  Andreas Rottmann  <a.rottmann@gmx.at>
603
604         * girepository/girnode.c (g_ir_node_build_typelib): Use sizeof()
605         instead of hard-coding struct sizes.
606
607 2008-11-18  Owen Taylor <otaylor@redhat.com>
608
609         Bug 561296 - Add "storage type" to the typelib data for enums
610
611         In order to set and get enum and flag fields in structures, we need
612         to know the integral type that the enumeration is stored as. We are already
613         computing that at compile time in order to compute struct offsets, so the
614         easiest thing to do is to save that in the typelib.
615
616         * docs/typelib-format.txt girepository/girnode.[ch] girepository/giroffsets.c
617         girepository/gtypelib.h: Add 'storage_type' to the typelib format for EnumBlob
618         and compute and save it at compile time.
619
620         * girepository/girepository.h girepository/ginfo.c:
621         Add g_enum_info_get_storage_type().
622
623         * girepository/gfield.c: Implement reading and writing enum and flags fields
624         based on the storage type.
625
626 2008-11-18  Owen Taylor <otaylor@redhat.com>
627
628         Add enums to the Everything test module
629
630         * tests/everything/everything.[ch]: Add TestEnum and TestFlags to the Everything
631         test module and register them as GTypes.
632
633         https://bugzilla.gnome.org/show_bug.cgi?id=561296
634
635 2008-11-18  Johan Dahlin  <jdahlin@async.com.br>
636
637         * giscanner/cachestore.py:
638         Catch BadPickleGet exceptions as well.  
639
640 2008-11-17  Owen Taylor  <otaylor@redhat.com>
641
642         * tests/everything/everything.c: Fix doc comment annotations
643         for test_struct_b_clone() to refer to the right function.
644
645 2008-11-17  Dan Winship  <danw@gnome.org>
646
647         * giscanner/glibtransformer.py (GLibTransformer.__init__): fix
648         spelling of GHashTable. #561135
649
650         * tests/scanner/annotation.c (annotation_object_get_hash):
651         * tests/scanner/annotation-1.0-expected.gir:
652         * tests/scanner/annotation-1.0-expected.tgir: add a test of
653         GHashTable annotations
654
655 2008-11-17  Andreas Rottmann  <a.rottmann@gmx.at>
656
657         * giscanner/ast.py: Change string array match type to be in terms
658         of canonicalized type.
659         * giscanner/transformer.py: Add canonicalize_ctype which gives us
660         a version of a c:type without aliases, so we can deep canonicalize
661         char** to utf8*.  Update parse_ctype to use it.
662         * tests/*: Add gtk_init like int*/char*** arg functions for testing.
663
664 2008-11-16  Colin Walters  <walters@verbum.org>
665
666         * girepository/girepository.c: Ensure we always call init_globals,
667         even if passed a non-default repository.
668
669 2008-11-16  Colin Walters  <walters@verbum.org>
670
671         Bug 559706 - Interface prerequisites
672
673         * common.mk: Dep on libgirepository.la for scanner libs so that
674         we rebuild things even if just gdump.c changes.
675         * girepository/gdump.c: Dump prerequisites.
676         * giscanner/ast.py: Add prerequisite list.
677         * giscanner/girparser.py: Parse them from gdump.
678         * giscanner/girwriter.py: Write them.
679         * giscanner/glibtransformer.py: Resolve them.
680         * tests/*: Test.
681
682 2008-11-16  Owen Taylor  <otaylor@redhat.com>
683
684         Bug 561087 - Respect is_pointer in serialize_type()
685
686         Add a '*' to the serialization for the cases where we set is_pointer
687         in the type blob we write out depending on node->is_pointer. Don't
688         add the '*' in the cases where is_pointer is set or not set in a
689         fixed fashion.
690
691         http://bugzilla.gnome.org/show_bug.cgi?id=561087
692
693 2008-11-16  Owen Taylor  <otaylor@redhat.com>
694
695         Bug 560825 – Add size and alignment to typelib
696
697         Include the size and alignment of structures and unions in the typelib,
698         and add getter methods to retrieve them from GIStructInfo/GIUnionInfo.
699
700         * docs/typelib-format.txt girepository/gtypelib.h girepository/girnode.c
701         girepository/girmodule.c girepository/gtypelib.c: Add size and alignment
702         to StructBlob and UnionBlob.
703
704         * girepository/ginfo.c girepository/girepository.h:
705         Add g_[struct|union]_get[size|alignment]().
706
707         * test/offsets/gen-gitestoffsets: Test overall structure size and alignment.
708
709 2008-11-16  Owen Taylor  <otaylor@redhat.com>
710
711         Bug 552371 – implement struct field get/set
712
713         * girepository/gfield.c girepository/girepository.h: Add
714         convenience functions g_field_info_set_field() and
715         g_field_info_get_field() to set and get fields based on the
716         offsets in GIFieldInfo.
717
718 2008-11-16  Andreas Rottmann  <a.rottmann@gmx.at>
719
720         Bug 560241 - Out-arguments should not be marked as being pointers
721         in all cases
722
723         * girepository/girparser.c: Improved logic for out arguments.
724
725 2008-11-16  Andreas Rottmann  <a.rottmann@gmx.at>
726
727         Bug 559601 - Pointers in structs/unions unduly treated as arrays
728
729         * giscanner/transformer.py: Differentiate type creation logic
730         between parameters and struct components.
731
732 2008-11-15  Colin Walters  <walters@verbum.org>
733
734         * giscanner/dumper.py: Check return code from pkg-config
735         invocations.
736
737 2008-11-14  Johan Dahlin  <jdahlin@async.com.br>
738
739         * tests/everything/everything.c (test_array_int_in),
740         (test_array_gtype_in):
741         * tests/everything/everything.h:
742         Rename the int/gtype array tests. Make the return value
743         useful, an aggregation of the array input values.
744
745 2008-11-14  Johan Dahlin  <jdahlin@async.com.br>
746
747         * tests/everything/Makefile.am:
748         * tests/everything/everything.c:
749         * tests/everything/everything.h:
750         * tests/everything/gitesttypes.c:
751         * tests/everything/gitesttypes.h:
752         Rename gitesttypes.[ch] to everything.[ch]
753
754 2008-11-13  Andreas Rottmann  <a.rottmann@gmx.at>
755
756         Bug 560708 – Don't treat arrays that have a length specified as
757         zero-terminated by default
758
759         * giscanner/transformer.py: Default to non zero terminated for
760         arrays with length.
761         * tests/*: Update, add test for zero vs not.
762
763 2008-11-13  Andreas Rottmann  <a.rottmann@gmx.at>
764
765         Bug 557788 - Return types for constructors in generated typelib bogus
766
767         * girepository/girnode.c: Namespace-qualify XREFs; not doing so is
768         obviously broken in the face of duplicate names in different
769         namespaces.
770         * tests/scanner/*expected.gir: Fix up.
771
772 2008-11-13  Owen Taylor  <otaylor@redhat.com>
773
774         * girepository/girffi.c: Fix  "Unexpected time for time_t"
775         message.
776
777 2008-11-13  Colin Walters  <walters@verbum.org>
778
779         Bug 558436 - avoid having scanner load app code
780
781         * giscanner/cgobject.py: Delete; we no longer load shared
782         libraries directly.
783         * giscanner/dumper.py: Support for linking a library to
784         a stub binary for introspection.
785         * giscanner/glibtransformer.py: Rewrite to use gdump XML
786         from invocation of child binary.
787         * giscanner/transformer.py: Fix up to use fully qualified
788         name in parse tree.  Make parse_ctype public so we can use
789         it inside glibtransformer.
790         * tests/scanner/barapp.c: New test, using --program arg
791         for g-ir-scanner.
792         * tests/*: Update to use common.mk for invoking scanner.
793         * tools/g-ir-scanner: Add options --program, --program-arg,
794         and --no-libtool.
795         * docs/g-ir-scanner.1: Update.
796
797 2008-11-13  Colin Walters  <walters@verbum.org>
798
799         * configure.ac: Depend on Gio, we use it in gdump.c.
800         * girepository/gdump.c: Code to dump GType data to XML.
801         * girepository/girepository.c: Add option group for dumping.
802         * girepository/girepository.h: Define API for the above.
803
804 2008-11-13  Colin Walters  <walters@verbum.org>
805
806         * common.mk: Add a file to include with Makefile fragments
807         useful for scanner invocation.
808
809 2008-11-13  Tommi Komulainen  <tommi.komulainen@iki.fi>
810
811         * tests/everything/gitesttypes.c (test_filename_return): Return
812         strings in filename encoding.
813
814 2008-11-13  Owen Taylor  <otaylor@redhat.com>
815
816         Bug 560253 – Add structure and boxed types to Everything test module
817
818         * tests/everything/gitesttypes.[ch]: Add examples of:
819
820           Plain old data structs
821           Plain old data structs with nested fields
822           Plain old data boxed
823           Plain old data boxed with nested fields
824           More complicated boxed types with internal state
825
826 2008-11-12  Johan Dahlin  <jdahlin@async.com.br>
827
828         * tests/everything/gitesttypes.c (test_gtype_in):
829         * tests/everything/gitesttypes.h:
830         Add a test of GType arrays, a la gtk_list_store_set_columns.
831
832 2008-11-12  Owen Taylor  <otaylor@redhat.com>
833
834         Bug 560419 – Cache includes when parsing
835
836         Keep track of all modules parsed within a GIrParser, and when a
837         module is referenced a second time, use the existing parsed copy
838         instead of reparsing.
839
840 2008-11-12  Owen Taylor  <otaylor@redhat.com>
841
842         Fix management of ParseContext.includes_modules (#560419)
843
844         * girepository/girparser.c: Fix some trivial bugs in managing the
845         list of include modules. (Add to module's list twice, not
846         initialized to NULL, not freed.)
847
848 2008-11-12  Owen Taylor  <otaylor@redhat.com>
849
850         Keep aliases and disguised_structures local to each module (#560419)
851
852         * girepository/girmodule.[ch]: When parsing, keep keep a separate
853         hash tables of aliases and 'disguised' flags for each module, and
854         store that on the module.
855
856         After parsing an include merge the aliases/disguised flags to the
857         including module.
858
859         * girepository/girparser.c: Remove 'prefix_aliases' flag and
860         always prefix aliases/disguised structure types when parsing; this
861         simplifies the code considerably.
862
863 2008-11-12  Owen Taylor  <otaylor@redhat.com>
864
865         Fix mismatches between .gir name and 'name' attribute (#560419)
866
867         * tests/boxed.gir tests/constant.gir tests/enum.gir tests/invoke/invoke.c
868         tests/invoke/testfns-1.0.gir tests/object.gir tests/struct.gir: Fix places
869         where the 'name' element of <namespace/> didn't match the filename of the
870         gir, an assumption that the compiler has always expected and now enforces.
871
872 2008-11-12  Owen Taylor  <otaylor@redhat.com>
873
874         Only allow one <namespace/> element per <repository/> (#560419)
875
876         * girepository/girparser.c: The logic in girparser.c didn't work
877         very well if there were multiple <namespace/> nodes within a
878         single <repository/> (context->namespace was always the overall
879         filename and not the the name specified in the <namespace/>
880         element for one thing; this would cause aliases to be mis-prefixed
881         in include modules.) Also check that the "name" in the
882         <namespace/> node matches the filename.
883
884 2008-11-12  Owen Taylor  <otaylor@redhat.com>
885
886         Add a GirParser object to hold the state of a compilation
887
888         * girepository/girparser.[ch] tools/compiler.c: Add a toplevel
889         GirParser object to hold state that is global across a
890         compilation. Currently just holds the include path, but will
891         eventually also keep a cached list of parsed modules.
892
893 2008-11-12  Tommi Komulainen  <tommi.komulainen@iki.fi>
894
895         * girepository/girepository.c (find_namespace_latest): Fix
896         minor memory leak.
897
898 2008-11-12  Tommi Komulainen  <tommi.komulainen@iki.fi>
899
900         * configure.ac: use 'introspection' component for bugs
901
902 2008-11-12  Johan Dahlin  <jdahlin@async.com.br>
903
904         * tests/everything/gitesttypes.c (test_filename_return):
905         * tests/everything/gitesttypes.h:
906         Add a filename return test.
907
908 2008-11-12  Tommi Komulainen  <tommi.komulainen@iki.fi>
909
910         * tests/offsets/Makefile.am (gitestoffsets.c): fix
911         gen-gitestoffsets invocation with builddir != srcdir
912
913 2008-11-12  Johan Dahlin  <jdahlin@async.com.br>
914
915         * girepository/girepository.c:
916         Change the element type from utf8 to filename
917         * girepository/girnode.c (g_ir_node_build_typelib):
918         Special case filename equally to utf8 here.
919
920 2008-11-12  Johan Dahlin  <jdahlin@async.com.br>
921
922         * gir/Makefile.am:
923         Remove unused variables, add a dependency of girepository.ch, so when
924         they change we rebuild the gir automatically.
925
926 2008-11-12  Johan Dahlin  <jdahlin@async.com.br>
927
928         * girepository/girepository.c (g_irepository_get_search_path):
929         * girepository/girepository.h:
930         Add a g_irepository_get_search_path, so we can access the search
931         paths from runtime.
932
933 2008-11-12  Johan Bilien  <jobi@via.ecp.fr>
934
935         Bug 560474 – g-ir-compiler crashes when compiling the glib gir
936
937         * girepository/girparser.c: avoid freeing an uninitialized pointer
938
939 2008-11-12  Johan Dahlin  <jdahlin@async.com.br>
940
941         * gir/Makefile.am:
942         * giscanner/glibtransformer.py:
943         * tools/g-ir-scanner:
944         Add a GIRepository-2.0.gir. Change the libtool lookup slightly
945         so we can just pass in --library=foo/bar/baz.la and the scanner
946         does the right thing.
947         Don't warn for _get_type() functions if they don't take any
948         parameters
949
950 2008-11-11  Owen Taylor  <otaylor@redhat.com>
951
952         Bug 560404 – Prefix types when resolving aliases in included modules
953
954         * girepository/girparser.c: When resolving aliases in an included
955         module, prefix types before looking them up.
956
957 2008-11-11  Owen Taylor  <otaylor@redhat.com>
958
959         Compute field offsets and overall size for object structures
960
961         Bug 560326 – Fails to build Gtk-2.0.typelib with "Unexpected non-pointer
962         field of type object in structure"
963
964         Do basic computation of field offsets for objects and interfaces;
965         this doesn't attempt to address all of the "mess" for virtual
966         functions described in Bug 560281.
967
968 2008-11-11  Tommi Komulainen  <tommi.komulainen@iki.fi>
969
970         Bug 560308 – g-ir-compiler goes in infinite loop on Gdk-2.0.gir
971
972         Based on patch by Johan Bilien.
973
974         * giscanner/transformer.py (_create_member, _create_parameter):
975         Resolve types here as well.
976         (_resolve_type_name_1): Try resolving using 'ctype' first since
977         it's least ambiguous. Fixes struct member type resolution with
978         similarly named types, e.g. Gdk.PangoRendererClass and
979         Pango.RendererClass
980         * tests/scanner/foo*: Add test.
981
982 2008-11-11  Owen Taylor  <otaylor@redhat.com>
983
984         * girepository/girparser.c: Search provided include dirs before
985         the default directories.
986
987 2008-11-11  Owen Taylor  <otaylor@redhat.com>
988
989         * girepository/giroffsets.c: Include fully-qualified names in
990         all error messages.
991
992 2008-11-11  Owen Taylor  <otaylor@redhat.com>
993
994         * girepository/giroffsets.c: Fail gracefully with an informative
995         error message when recursion is encountered when computing a 
996         structure size.
997
998 2008-11-11  Owen Taylor  <otaylor@redhat.com>
999
1000         * girepository/girparser.c: Remove an unused variable.
1001
1002 2008-11-10  Owen Taylor <otaylor@redhat.com>
1003
1004         Add tests for field offset computations
1005
1006         * tests/offsets/offsets.h: Header file with structure definitions to test
1007
1008         * tests/offsets/gen-gitestoffsets: Generate a C program that computes
1009         field offsets for the structures in offsets.h two ways: using
1010         the information from a generated typelib, and as computed by the
1011         compiler.
1012
1013         We diff these two versions to test that everything is OK.
1014
1015 2008-11-10  Owen Taylor <otaylor@redhat.com>
1016
1017         Remove field offsets from g-ir-generate output and test inputs
1018
1019         Field offsets are a) architecture dependent so they shouldn't be part
1020         of the architecture-independent gir format which is installed in
1021         datadir. b) Are architecture-dependent so they shouldn't be in test
1022         expected output.
1023
1024         * girepository/girparser.c: Don't parse offset for fields
1025         * tools/generate.c: Don't parse offset for fields
1026         * tests/*.gir test/scanner/*.tgir: Remove offsets
1027
1028         (Virtual function and discriminator offsets are not removed, as they
1029         aren't fully hooked up to the field-offset computation machinery yet.)
1030
1031 2008-11-10  Owen Taylor <otaylor@redhat.com>
1032
1033         Bug 560252 - Compute field offsets before writing typelib
1034
1035         * girepository/girnode.h: Store the total size and alignment for
1036         GIrNodeStruct/Boxed/Union.
1037
1038         * girepository/giroffset.c: New file implementing computation of
1039         structure field offsets.
1040
1041         * girepository/girnode.c: Compute structure field offsets before
1042         writing types into the typelib.
1043
1044         * docs/typelib-format.txt: Document that a field offset of 0xFFFF
1045         means "unknown". Also fix description of the discriminator_offset
1046         field for unions.
1047
1048 2008-11-10  Owen Taylor <otaylor@redhat.com>
1049
1050         Bug 560250 - Fully parse included modules
1051
1052         For some things, like computing structure offsets to put into the typelib
1053         we need more than just the aliases from included modules. Do a completel
1054         parse of included modules and store in module->included_modules.
1055
1056         Also add g_ir_find_node() to find node information from within the
1057         active set of modules and their includes.
1058
1059 2008-11-10  Owen Taylor <otaylor@redhat.com>
1060
1061         Split g_ir_ffi_get_ffi_type() out from ginvoke.c
1062
1063         Extract a function to convert GITypeTag to ffi_type from the internals
1064         of ginvoke.c. This will be useful in figure out structure alignment.
1065
1066         Also fix handling of gsize and time_t to be portable. (Add a check
1067         to configure.ac to figure out the width of time_t.)
1068
1069 2008-11-10  Owen Taylor <otaylor@redhat.com>
1070
1071         Bug 560248 – "disguised structures"
1072
1073         Certain types like GIConv and GdkAtom are pointers internally but don't
1074         look like pointers when referenced. They have the form.
1075
1076           typedef struct _X *X;
1077
1078         Parse these as structures/records but mark them in the gir with a 'disguised'
1079         attribute so that we know that they need special handling.
1080
1081         In the typelib treat them like any other structure.
1082
1083 2008-11-09  Jürg Billeter  <j@bitron.ch>
1084
1085         * giscanner/ast.py:
1086         * giscanner/girwriter.py:
1087
1088         Write throws attribute for virtual functions, fixes bug 559703
1089
1090 2008-11-07  Johan Dahlin  <jdahlin@async.com.br>
1091
1092         * giscanner/libtoolimporter.py (LibtoolImporter.find_module): Clear
1093         up some confusion about the second argument to find_module, it's
1094         actually the packages __path__ attribute which we can safely ignore
1095         for our purposes.
1096         (LibtoolImporter.load_module): Set module.__loader__ as per PEP 302.
1097
1098 2008-11-07  Owen Taylor  <otaylor@redhat.com>
1099
1100         Bug 559737 – Deal with continuations in macros
1101
1102         * giscanner/giscannerlexer.l: Treat continuation lines the same
1103         as regular newlines. This makes the scanner not complain about
1104         #define foo(x) \ <stuff> inside a C file. There's no attempt
1105         however to handle parsing macro definitions split across lines.
1106
1107 2008-11-07  Johan Dahlin  <jdahlin@async.com.br>
1108
1109         * giscanner/cachestore.py:
1110         Handle broken cache entries, write only filesystems and
1111         running out of diskspace.
1112
1113 2008-11-07  Owen Taylor  <otaylor@redhat.com>
1114
1115         * giscanner/giscannermodule.c (pygi_source_scanner_lex_filename):
1116         Set current_filename before lexing the file so error messages
1117         are reported in the right file.
1118
1119 2008-11-06  Colin Walters  <walters@verbum.org>
1120
1121         * tests/everything/*: Add some tests for strv.
1122
1123 2008-11-05  Colin Walters  <walters@verbum.org>
1124
1125         * girepository/ginvoke.c (g_function_info_invoke): Don't use
1126         nested scope local variable for error which may go away after
1127         conditional is complete.
1128
1129 2008-11-05  Colin Walters  <walters@verbum.org>
1130
1131         * giscanner/scannerlexer.l: Avoid static 256 char buf which we
1132         manipulate hackily; just use GString.  This avoids an
1133         uninitialized memory read pointed out by Havoc.
1134
1135 2008-11-04  Johan Dahlin  <jdahlin@async.com.br>
1136
1137         * giscanner/__init__.py:
1138         * giscanner/ast.py:
1139         * giscanner/cachestore.py:
1140         * giscanner/cgobject.py:
1141         * giscanner/girparser.py:
1142         * giscanner/girwriter.py:
1143         * giscanner/giscannermodule.c:
1144         * giscanner/glibast.py:
1145         * giscanner/glibtransformer.py:
1146         * giscanner/libtoolimporter.py:
1147         * giscanner/minixpath.py:
1148         * giscanner/odict.py:
1149         * giscanner/sourcescanner.c:
1150         * giscanner/sourcescanner.h:
1151         * giscanner/sourcescanner.py:
1152         * giscanner/transformer.py:
1153         * giscanner/utils.py:
1154         * giscanner/xmlwriter.py:
1155         * COPYING:
1156         Relicense the giscanner library under LGPLv2+.
1157         This has been approved by all contributors.
1158
1159 2008-11-01  Owen Taylor  <otaylor@redhat.com>
1160
1161         Bug 558848 giparser.py: shared library should be optional
1162
1163         When parsing a .gir, allow the shared-library attribute
1164         of <namespace/> to be missing: this corresponds to the handling
1165         in libgirepository and elsewhere.
1166
1167 2008-11-01  Tommi Komulainen  <tommi.komulainen@iki.fi>
1168
1169         Bug 557898 – Fails to build on OSX 10.4
1170
1171         * configure.ac: Check for $shrext_cmds that should be implicitly
1172         available if you're using libtool >= 2.0. If undefined, call
1173         libtool --config explicitly to get its value.
1174         * girepository/gtypelib.c: Remove special case for (non-)Darwin
1175         systems as unneeded.
1176
1177 2008-10-31  Colin Walters  <walters@verbum.org>
1178
1179         * COPYING, COPYING.lib, COPYING.tools: Clarify licensing status.
1180
1181 2008-10-31  Johan Dahlin  <jdahlin@async.com.br>
1182
1183         * configure.ac: Post release version bump
1184
1185 === 0.6.0 ===
1186 2008-10-31  Johan Dahlin  <jdahlin@async.com.br>
1187
1188         * NEWS:
1189         * configure.ac:
1190         * docs/release-checklist.txt:
1191         0.6.0
1192
1193 2008-10-31  Johan Dahlin  <jdahlin@async.com.br>
1194
1195         * Makefile.am: add an upload-release target
1196         * docs/release-checklist.txt:
1197         Release process documentation
1198
1199 2008-10-31  Colin Walters  <walters@verbum.org>
1200
1201         Bug 558109 – _g_typelib_init fails to find shared libraries
1202
1203         * transformer/glibtransformer.py: Use ctypes' find_library
1204         on passed libraries and write that for the shared-library
1205         entry.  We want to avoid depending on -devel packages.
1206
1207 2008-10-31  Johan Dahlin  <jdahlin@async.com.br>
1208
1209         * docs/g-ir-scanner.1:
1210         Document the renaming options.
1211
1212 2008-10-31  Tommi Komulainen  <tommi.komulainen@iki.fi>
1213
1214         * giscanner/Makefile.am:
1215         * tests/invoke/Makefile.am:
1216         * tests/repository/Makefile.am: List in-tree libraries first in
1217         LDADD / LIBADD. If installed library is listed first, the
1218         resulting binary will prefer installed version to one in .libs,
1219         possibly making 'make check' behave strangely.
1220
1221 2008-10-30  Tommi Komulainen  <tommi.komulainen@iki.fi>
1222
1223         * giscanner/ast.py: map 'id' (ObjC) to 'any' type to stop
1224         gir-repository from choking with gdk/quartz
1225
1226 2008-10-30  Johan Dahlin  <jdahlin@async.com.br>
1227
1228         * giscanner/giscannermodule.c (calc_attrs_length),
1229         (pygi_collect_attributes):
1230         * giscanner/xmlwriter.py:
1231         Write a C version of the xml namespace formatter.
1232         Saves 15% of the time it takes to create a gtk gir.
1233
1234 2008-10-30  Johan Dahlin  <jdahlin@async.com.br>
1235
1236         * giscanner/xmlwriter.py: Abstract attribute formatting
1237         to a function external to the XMLWriter class.
1238
1239         * giscanner/scannerlexer.l:
1240         Parse and discard __typeof and __attribute.
1241
1242 2008-10-30  Johan Dahlin  <jdahlin@async.com.br>
1243
1244         * giscanner/girparser.py:
1245         Remove arguments from the constructor, move them to
1246         separate accessors. Add a new parse_tree method
1247         which takes an element tree instance.
1248         * tools/g-ir-scanner:
1249         Update callsite for this
1250
1251         * giscanner/Makefile.am:
1252         * giscanner/cachestore.py:
1253         * giscanner/transformer.py:
1254         Cache the include parsing. Saves ~25% time when
1255         creating vte (which includes everything up to gtk+).
1256
1257 2008-10-30  Colin Walters  <walters@verbum.org>
1258
1259         * giscanner/transformer.py: Don't reparse includes
1260         we've already processed.
1261
1262 2008-10-30  Johan Dahlin  <jdahlin@async.com.br>
1263
1264         * giscanner/girparser.py:
1265         * giscanner/transformer.py:
1266         Avoid parsing parameters, types etc when parsing
1267         includes. Should speed up include parsing a bit.
1268
1269 2008-10-30  Johan Dahlin  <jdahlin@async.com.br>
1270
1271         * giscanner/girparser.py:
1272         Avoid big if/else and use a dispatch table like
1273         approach.
1274
1275 2008-10-30  Johan Dahlin  <jdahlin@async.com.br>
1276
1277         * giscanner/transformer.py:
1278         Clean up include parsing and registration.
1279
1280 2008-10-30  Johan Dahlin  <jdahlin@async.com.br>
1281
1282         * giscanner/transformer.py:
1283         Clean up imports
1284
1285 2008-10-30  Johan Dahlin  <jdahlin@async.com.br>
1286
1287         Bug 558383 – builddir != srcdir build fails if giscanner python module not already installed
1288
1289         * gir/Makefile.am:
1290         construct PYTHONPATH just once
1291
1292         * tests/everything/Makefile.am:
1293         * tests/scanner/Makefile.am:
1294         add $(top_srcdir) to PYTHONPATH to
1295         handle builddir != srcdir
1296
1297         * giscanner/libtoolimporter.py:
1298         * giscanner/sourcescanner.py:
1299         Make the libtoolimporter work when distchecking too.
1300
1301         Mostly based on patch by Tommi Komulainen
1302
1303 2008-10-29  Owen Taylor  <otaylor@redhat.com>
1304
1305         * giscanner/glibtransformer.py: If a filename of an existing
1306         file is passed to --library, hunt for it directly, rather than
1307         searching for a corresponding library.
1308
1309 2008-10-29  Johan Dahlin  <jdahlin@async.com.br>
1310
1311         * giscanner/libtoolimporter.py:
1312         * giscanner/sourcescanner.py:
1313         Clean up the libtool importer a bit. Add a context so we
1314         can use it through a with statement.
1315         Don't just look in the current directory, look in the whole
1316         sys.path.
1317
1318 2008-10-29  Tommi Komulainen  <tommi.komulainen@iki.fi>
1319
1320         Bug 558065 – gitesttypes should be installed
1321
1322         * configure.ac:
1323         * tests/Makefile.am:
1324         * tests/types/Makefile.am   -> tests/everything/Makefile.am
1325         * tests/types/gitesttypes.c -> tests/everything/gitesttypes.c
1326         * tests/types/gitesttypes.h -> tests/everything/gitesttypes.h
1327         move tests/types to tests/everything
1328
1329         * tests/everything/Makefile.am: build normal shared library
1330         libgirepository-everything.so.1.0.0 and corresponding typelib
1331         Everything-1.0.typelib
1332
1333         * tests/everything/Makefile.am: explicitly link libtool
1334         versioning with typelib versioning with variables
1335
1336 2008-10-28  Johan Bilien  <jobi@via.ecp.fr>
1337
1338         * tools/g-ir-scanner: add LD_LIBRARY_PATH to LPATH before calling ld.
1339
1340 2008-10-27  Johan Bilien  <jobi@via.ecp.fr>
1341
1342         * gio/gio-2.0.c: add allow-none annotations, based on the pygobject
1343         .defs file
1344
1345 2008-10-27  Johan Bilien  <jobi@via.ecp.fr>
1346
1347         Bug 558068 – when invoking a method, offset the in arguments by one,
1348         not the out
1349
1350         * tests/invoke/invoke.c, tests/invoke/testfns.c,
1351         tests/invoke/testfns-1.0.gir: Add testing of method and constructor.
1352         * girepository/ginvoke.c: do not offset the index of given out
1353         arguments by one for methods, "this" is provided as in argument only.
1354
1355 2008-10-27  Johan Bilien  <jobi@via.ecp.fr>
1356
1357         * gir/gio-2.0.c: add annotation for g_file_delete
1358
1359 2008-10-27  Tommi Komulainen  <tommi.komulainen@iki.fi>
1360
1361         Bug 558062 – provide and use paths in the .pc file
1362
1363         * gobject-introspection-1.0.pc.in: provide typelibdir variable
1364         for where .typelibs should be installed (callers shouldn't need
1365         to construct paths from bits and pieces)
1366
1367 2008-10-25  Andreas Rottmann  <a.rottmann@gmx.at>
1368
1369         Bug 557791 – g_irepository_require() could return a GTypelib *
1370
1371         * girepository/girepository.c: Return GTypelib; this is useful
1372         for low level manipulation.
1373
1374 2008-10-25  Colin Walters  <walters@verbum.org>
1375
1376         Bug 557788 – Return types for constructors in generated typelib bogus
1377
1378         * giscanner/glibtransformer.py: Don't resolve ctors incrementally,
1379         rely on end pass resolution.
1380
1381 2008-10-25  Andreas Rottmann  <a.rottmann@gmx.at>
1382
1383         Bug 557786 - support fixed size arrays
1384
1385         * girepository/ginfo.c: Add g_type_info_get_array_fixed_size.
1386         * giscanner/scannerparser.y: Retain fixed array size.
1387         * giscanner/ast.py: Add to note.
1388         * giscanner/girwriter.py: Write to gir.
1389         * girepository/girnode.c: Write it to typelib.
1390         * tools/generate.c: Generate.
1391         * tests/*: Add tests.
1392
1393 2008-10-25  Colin Walters  <walters@verbum.org>
1394
1395         Bug 557076 - move typelibs to $libdir
1396
1397         * configure.ac: Steal some configury bits from dbus to expand
1398         libdir.
1399         * gir/Makefile.am: Move to libdir.
1400         * girepository/girepository.c: Stop searching XDG_DATA_DIRS;
1401         instead just look at one hardcoded path in libdir.
1402         * acinclude.m4: Bits from dbus.
1403
1404 2008-10-24  Johan Dahlin  <johan@gnome.org>
1405
1406         * girepository/girnode.c (g_ir_node_check_unhandled_members):
1407         Be quiet, do not warn about unhandled members.
1408
1409 2008-10-24  Johan Dahlin  <johan@gnome.org>
1410
1411         * girepository/gtypelib.c:
1412         Only use SHLIB_SUFFIX on darwin, otherwise use
1413         G_MODULE_SUFFIX, we cannot get shext_cmds from libtool 2.2.
1414
1415 2008-10-24  Lucas Rocha  <lucasr@gnome.org>
1416
1417         Bug 557623 - Constructors shouldn't be flagged as methods.
1418
1419         * girepository/ginfo.c (g_function_info_get_flags): ditto.
1420
1421 2008-10-24  Johan Dahlin  <johan@gnome.org>
1422
1423         * giscanner/scannerparser.y:
1424         Check against division by zero for the modula operator.
1425         This fixes header parsing of OSX system headers included
1426         by libsoup.
1427
1428 2008-10-24  Johan Dahlin  <johan@gnome.org>
1429
1430         * CONTRIBUTORS:
1431         * Makefile.am:
1432         Add a CONTRIBUTORS file and dist it.
1433
1434 2008-10-23  Tommi Komulainen  <tommi.komulainen@iki.fi>
1435
1436         Bug 556739 – transfer-ownership attribute should be mandatory in .gir
1437
1438         * girepository/girparser.c (parse_param_transfer):
1439         * giscanner/transformer.py (_create_parameter, _create_return):
1440         * giscanner/girwriter.py (_write_return, _write_parameter):
1441         * tools/generate.c (write_callable_info): always write and
1442         require "transfer-ownership" for return-values and parameters
1443
1444         * tests/boxed.gir:
1445         * tests/invoke/testfns-1.0.gir:
1446         * tests/object.gir:
1447         * tests/scanner/DrawableAdditions.xml:
1448         * tests/scanner/GtkFrob-1.0-expected.tgir:
1449         * tests/scanner/annotation-1.0-expected.tgir:
1450         * tests/scanner/drawable-1.0-expected.tgir:
1451         * tests/scanner/drawable-injected-1.0-expected.gir:
1452         * tests/scanner/drawable-injected-1.0-expected.tgir:
1453         * tests/scanner/foo-1.0-expected.tgir: Updated
1454
1455 2008-10-23  Tommi Komulainen  <tommi.komulainen@iki.fi>
1456
1457         * giscanner/cgobject.py: build fundamental types same way as glib
1458
1459         * giscanner/glibtransformer.py (_type_from_gtype): record GType
1460         when constructing the Type from it
1461
1462         * giscanner/glibtransformer.py (_adjust_transfer): Check whether
1463         the parameter is a GObject from its GType, if available.
1464
1465         * giscanner/glibtransformer.py (_adjust_transfer):
1466         * tests/scanner/foo-1.0-expected.gir:
1467         * tests/scanner/foo-1.0-expected.tgir: deduce
1468         transfer-ownership from GTypes
1469
1470 2008-10-23  Tommi Komulainen  <tommi.komulainen@iki.fi>
1471
1472         * giscanner/transformer.py (_create_parameter):
1473         * tests/scanner/foo-1.0-expected.gir: make varargs
1474         transfer-ownership="none"
1475
1476 2008-10-23  Colin Walters  <walters@verbum.org>
1477
1478         Bug 556739 - transfer ownership
1479
1480         * giscanner/ast.py: Refactor Parameter/Return to share
1481         common attributes.  Add transfer_inferred attribute
1482         which says whether or not we made a guess.
1483         * giscanner/transformer.py: Add much more extensive
1484         heuristics around parameter and return transfer.
1485         * giscanner/glibtransformer.py: Adjust to inspect
1486         transfer_inferred.
1487         * tests/*: Adjust.
1488
1489 2008-10-22  Tommi Komulainen  <tommi.komulainen@iki.fi>
1490
1491         Bug 557377 – Add test to ensure annotations survive the roundtrip via typelib
1492
1493         * tests/scanner/Makefile.am:
1494         * tests/scanner/annotation-1.0-expected.tgir:
1495         * tests/scanner/drawable-1.0-expected.tgir:
1496         * tests/scanner/drawable-injected-1.0-expected.tgir:
1497         * tests/scanner/foo-1.0-expected.tgir:
1498         * tests/scanner/GtkFrob-1.0-expected.tgir:
1499         * tests/scanner/utility-1.0-expected.tgir: Add test to ensure
1500         annotations survive the roundtrip via typelib
1501
1502         The expectations are as currently produced by g-ir-generate,
1503         comparison with the .gir files shows there are differences.
1504
1505 2008-10-23  Johan Bilien  <jobi@via.ecp.fr>
1506
1507         Bug 557468 – Support for GI_TYPELIB_PATH
1508
1509         * girepository/girepository.c: if the GI_TYPELIB_PATH is set, add the
1510         provided paths to the global search path.
1511
1512 2008-10-22  Tommi Komulainen  <tommi.komulainen@iki.fi>
1513
1514         Bug 557379 – g-ir-generate not writing the 'abstract' attribute
1515
1516         * tests/scanner/drawable-1.0-expected.tgir:
1517         * tests/scanner/drawable-injected-1.0-expected.tgir:
1518         * tests/scanner/foo-1.0-expected.tgir:
1519         * tools/generate.c (write_object_info): write 'abstract'
1520         attribute for classes
1521
1522 2008-10-22  Lucas Rocha  <lucasr@gnome.org>
1523
1524         * girepository/girmodule.c, girepository/gtypelib.c,
1525         girepository/girparser.[ch]: fix some build warnings.
1526
1527 2008-10-22  Tommi Komulainen  <tommi.komulainen@iki.fi>
1528
1529         Bug 557405 – Use 'allow-none' consistently
1530
1531         * docs/typelib-format.txt:
1532         * girepository/ginfo.c (g_arg_info_may_be_null):
1533         * girepository/girnode.c (g_ir_node_build_typelib):
1534         * girepository/girnode.h (struct _GIrNodeParam):
1535         * girepository/girparser.c (start_parameter):
1536         * girepository/girwriter.c (function_generate):
1537         * girepository/gtypelib.h (ArgBlob):
1538         * tests/errors.gir:
1539         * tests/function.gir:
1540         * tools/generate.c (write_callable_info): Use 'allow-none'
1541         consistently throughout
1542
1543 2008-10-22  Tommi Komulainen  <tommi.komulainen@iki.fi>
1544
1545         Bug 557092 – Callback annotations not used
1546
1547         * giscanner/transformer.py (_create_callback): use annotations
1548         for callbacks
1549         * tests/scanner/annotation.h
1550         * tests/scanner/annotation-1.0-expected.gir: add tests
1551
1552 2008-10-21  Colin Walters  <walters@verbum.org>
1553
1554         * giscanner/scannerlexer.l: Don't require trailing whitespace after
1555         uncommented parameters.
1556         * tests/*: Test it.
1557
1558 2008-10-21  Colin Walters  <walters@verbum.org>
1559
1560         * girepository/girepository.c: Ensure that when doing an unversioned
1561         require, we prefer items earlier in the search path to later ones.
1562
1563 2008-10-21  Owen Taylor  <otaylor@redhat.com>
1564
1565         * giscanner/transformer.py: For string parameters allow transfer annotation
1566         to override the standard automatic guessing based on 'const'.
1567
1568 2008-10-21  Johan Bilien  <jobi@via.ecp.fr>
1569
1570         Bug 557241 – "throws" flag for functions
1571
1572         * tests/scanner/drawable-1.0-expected.gir,
1573         tests/scanner/drawable-injected-1.0-expected.gir,
1574         tests/scanner/drawable.[ch]: add simple test for throwing
1575         function (has GError ** as last argument)
1576
1577         * giscanner/ast.py: add a 'throws' flag to Function
1578         * giscanner/glibtransformer.py: if a function's last paramerter is
1579         a GError, set the 'throws' flag and remove that parameter
1580         * giscanner/girwriter.py: write out the 'throws' attribute
1581         * giscanner/girparser.py: support parsing the 'throws' attribute
1582
1583         * tests/repository/gitestthrows.c: add a simple test to check the
1584         throws flag in a typelib and invoke the function
1585
1586         * girepository/ginfo.c, girepository/girnode.[ch],
1587         girepository/girnode.h, girepository/girparser.c,
1588         girepository/girepository.h: Add and parse the GI_FUNCTION_THROWS flag
1589
1590         * girepository/ginvoke.c: if a function throws, add a GError as last
1591         arguments, and propagate the error to the invoker.
1592
1593 2008-10-21  Tommi Komulainen  <tommi.komulainen@iki.fi>
1594
1595         * giscanner/transformer.py (_create_parameters): Warn if we see
1596         annotations for unknown parameters. If .h and .c files name
1597         parameters differently, the annotations may be lost.
1598
1599 2008-10-21  Johan Dahlin  <johan@gnome.org>
1600
1601         Bug 556358 - don't use libtool internals
1602
1603         * giscanner/Makefile.am:
1604         * giscanner/libtoolimporter.py:
1605         * giscanner/sourcescanner.py:
1606         * giscanner/utils.py:
1607         Add a python meta importer and remove a libtool symlink hack.
1608
1609 2008-10-20  Andreas Rottmann  <a.rottmann@gmx.at>
1610
1611         * tests/scanner/Makefile.am (%.typelib): Set PYTHONPATH
1612         and --add-include-path appropriately when invoking the scanner.
1613         * tests/types/Makefile.am (%typelib): Likewise.
1614
1615 2008-10-20  Colin Walters  <walters@verbum.org>
1616
1617         Bug 556777 - validate properties
1618
1619         * giscanner/transformer.py: Add option to throw on unknown types.
1620         * giscanner/glibtransformer.py: Use it on properties.
1621         * tests/*: Add a test.
1622
1623 2008-10-20  Colin Walters  <walters@verbum.org>
1624
1625         * giscanner/glibast.py: Also register g variants of
1626         default_array_types.  This is not beautiful, but
1627         good alternatives aren't easy to come by.
1628         This fixes gchar ** parsing.
1629
1630 2008-10-20  Colin Walters  <walters@verbum.org>
1631
1632         * docs/typelib-format.txt, girepository/gtypelib.h:
1633         Take a bit from ObjectInfo to represent abstract flag.
1634         * giscanner/cgobject.py: Expose g_type_get_flags.
1635         * girepository/girepository.h: Add accessor.
1636         * girepository/ginfo.c: Implement it.
1637         * giscanner/ast.py: Add is_abstract flag to generic
1638         class object.
1639         * giscanner/glibast.py: Use it.
1640         * giscanner/girwriter.py: Write it.
1641         * girepository/girparser.c: Parse it.
1642         * tests/*: Test it.
1643
1644 2008-10-20  Tommi Komulainen  <tommi.komulainen@iki.fi>
1645
1646         * giscanner/girparser.py (_parse_function): don't lose
1647         'transfer-ownership' attributes when injecting, check for the
1648         correct attribute
1649
1650 2008-10-19  Johan Dahlin  <johan@gnome.org>
1651
1652         * giscanner/scannerlexer.l: Parse and ignore __asm.
1653
1654 2008-10-19  Colin Walters  <walters@verbum.org>
1655
1656         * giscanner/girparser.py: Parse array length= to ensure
1657         it doesn't get lost from --inject.
1658
1659 2008-10-17  Colin Walters  <walters@verbum.org>
1660
1661         Bug 556795 - char ** regression
1662
1663         * giscanner/transformer.py: Fix parsing of ctypes, add some
1664         comments about what's going on.
1665         * tests/*: Add a test for char **.
1666
1667 2008-10-17  Colin Walters  <walters@verbum.org>
1668
1669         Bug 556783 - change namespace handling to be more consistent
1670
1671         * giscanner/transformer.py: Eliminate usage of
1672         strip_namespace_object.  We now treat --namespace as the default
1673         --strip-prefix; however, if --strip-prefix is specified it
1674         overrides --namespace.  This applies to everything except function
1675         names, where we do also strip the namespace.
1676         * giscanner/glibtransformer.py: Remove usage of
1677         strip_namespace_object.
1678         * tests/*: Update.
1679         * tests/*: Add skeletal GtkFrob-1.0 test which has different
1680         --namespace and --strip-prefix.
1681
1682 2008-10-17  Tommi Komulainen  <tommi.komulainen@iki.fi>
1683
1684         Bug 556732 – generate gir files consistently
1685
1686         * girepository/girparser.c (start_parameter):
1687         * tests/boxed.gir:
1688         * tests/invoke/testfns-1.0.gir:
1689         * tools/generate.c (write_callable_info): write
1690         'transfer-ownership' attribute consistently with both
1691         return-value and parameter elements
1692
1693 2008-10-17  Tommi Komulainen  <tommi.komulainen@iki.fi>
1694
1695         Bug 556732 – generate gir files consistently
1696
1697         * tools/generate.c (write_callable_info): write 'direction'
1698         attribute only if other than 'in' to be consistent with
1699         girwriter.py
1700         * tests/boxed.gir:
1701         * tests/object.gir: remove direction="in" which is the default
1702
1703 2008-10-17  Tommi Komulainen  <tommi.komulainen@iki.fi>
1704
1705         Bug 556732 – generate gir files consistently
1706
1707         * giscanner/ast.py (Field): add readable and writable properties
1708         * giscanner/girparser.py (_parse_field): copy 'readable' and
1709         'writable' attributes
1710         * giscanner/transformer.py (_create_member): create fields as
1711         read-write
1712         * giscanner/glibtransformer.py (_introspect_object,
1713         _pair_class_struct): make object instance and class fields
1714         read-only
1715         * giscanner/girwriter.py (_write_field):
1716         * tools/generate.c (write_field_info): write field 'readable'
1717         and 'writable' attributes only if non-default (read-only)
1718         * girepository/girparser.c (start_field): in the absence of
1719         attributes assume fields are read-only
1720         * tests/boxed.gir:
1721         * tests/struct.gir: remove redundant readable="1" from fields
1722         * tests/scanner/foo-1.0-expected.gir:
1723         * tests/scanner/utility-1.0-expected.gir: add writable="1" to
1724         all record and union fields
1725
1726 2008-10-17  Tommi Komulainen  <tommi.komulainen@iki.fi>
1727
1728         Bug 556732 – generate gir files consistently
1729
1730         * giscanner/girwriter.py (_write_property): write properties
1731         'construct' attribute if set
1732         * tools/generate.c (write_property_info): write properties
1733         'readable' and 'writable' attributes only if non-default
1734         * tests/object.gir: add writable="0"
1735         * tests/scanner/foo-1.0-expected.gir: add construct="1"
1736
1737 2008-10-17  Johan Bilien  <jobi@via.ecp.fr>
1738
1739         * gir/glib-2.0.c: added annotations
1740
1741 2008-10-16  Johan Bilien  <jobi@via.ecp.fr>
1742
1743         * giscanner/ast.py: Also assume direction=out for size_t*, ssize_t*
1744         arguments
1745
1746 2008-10-16  Johan Bilien  <jobi@via.ecp.fr>
1747
1748         Bug 556610 – giscanner/girparser.py drops parameter options
1749
1750         * tests/scanner/drawable-injected-1.0-expected.gir,
1751         tests/scanner/DrawableAdditions.xml: added simple test for injection.
1752         * giscanner/ast.py: allow Parameter to take options in the constructor
1753         * giscanner/girparser.py: parse parameter options (transfer,
1754         direction, allow-none)
1755
1756 2008-10-16  Colin Walters  <walters@verbum.org>
1757
1758         Bug 556185 - segfault on g_callable_info_get_return_type
1759
1760         Initial patch from John Ehresman.
1761
1762         * tests/repository/*: Add a test using
1763         g_callable_info_get_return_type.  Instead of casting a
1764         GITypeInfo directly to a GIRegisteredTypeInfo, we need
1765         to call g_type_info_get_interface.
1766
1767 2008-10-16  Colin Walters  <walters@verbum.org>
1768
1769         Bug 556579 - union and struct name misresolved
1770
1771         * giscanner/transformer.py: The calls to _resolve_type_name
1772         for struct/union names was a legacy holdover from when type
1773         resolution had multiple phases.  Now it's actively harmful
1774         since we might pull in an identical name from another
1775         namespace.
1776         * tests/*: Update.
1777
1778 2008-10-16  Colin Walters  <walters@verbum.org>
1779
1780         Bug 556432 - transfer annotations and defaults
1781
1782         * giscanner/transformer.py: Canonicalize type
1783         after removing *, not before.  This ensures that
1784         guchar* is transformed to 'uint8'.
1785         Add some comments here.
1786         * giscanner/glibtransformer.py: Add _adjust_transfer
1787         phase for tweaking GObject transfers.
1788         * tests/*: test it.
1789
1790 2008-10-16  Tommi Komulainen  <tommi.komulainen@iki.fi>
1791
1792         * configure.ac: enable bunch of gcc warning CFLAGS
1793
1794 2008-10-16  Tommi Komulainen  <tommi.komulainen@iki.fi>
1795
1796         Bug 556543 – reduce compiler warnings
1797
1798         * girepository/ginfo.c:
1799         * girepository/girepository.c (register_internal,
1800         count_interfaces, find_interface, find_namespace_version,
1801         parse_version, g_irepository_require):
1802         * girepository/girmodule.c (g_ir_module_build_typelib):
1803         * girepository/girnode.c (init_stats, dump_stats,
1804         _g_irnode_init_stats, _g_irnode_dump_stats,
1805         g_ir_node_can_have_member):
1806         * girepository/girparser.c (firstpass_end_element_handler,
1807         locate_gir, parse_basic, parse_type_internal, resolve_aliases,
1808         start_alias, start_type, end_type_top, parse_include, cleanup,
1809         post_filter):
1810         * girepository/gtypelib.c (validate_function_blob, validate_enum_blob):
1811         * giscanner/giscannermodule.c (directive_get_options,
1812         type_get_child_list):
1813         * giscanner/scannerlexer.l (parse_gtkdoc):
1814         * giscanner/scannerparser.y (ctype_free):
1815         * giscanner/sourcescanner.c:
1816         * giscanner/sourcescanner.h (gi_source_scanner_parse_macros):
1817         * tests/types/gitesttypes.c:
1818         * tools/compiler.c (main):
1819         * tools/generate.c (write_repository): Remove unused variables
1820         and code, add missing includes, declarations and case
1821         statements.
1822
1823 2008-10-16  Tommi Komulainen  <tommi.komulainen@iki.fi>
1824
1825         Bug 556541 – access union members through UnionBlob rather than
1826         StructBlob
1827
1828         * girepository/ginfo.c (g_union_info_find_method): access union
1829         members through UnionBlob rather than StructBlob
1830
1831 2008-10-15  Colin Walters  <walters@verbum.org>
1832
1833         Bug 556331 - clean up includes handling
1834
1835         * tools/g-ir-scanner: Rework command line arguments; now we take
1836         --add-include-path and --include separately.
1837         * giscanner/girwriter.py: Separate name= and version= in include
1838         directives.
1839         * giscanner/ast.py: Add Include type.
1840         * giscanner/transformer.py: Cleanups to register_include now that
1841         we don't need to handle mixed filenames and relative arguments.
1842         * girepository/girparser.c: Parse name and version separately;
1843         this fixes a bug as a side effect where we weren't resolving
1844         through aliases for basic types.
1845         * girepository/girepository.c: Fix format string args.
1846         * gir/Makefile.am: Update.
1847         * tests/*: Update.
1848
1849 2008-10-15  Tommi Komulainen  <tommi.komulainen@iki.fi>
1850
1851         Bug 556434 – unhandled interface/object/... member types
1852
1853         * girepository/girnode.c (g_ir_node_check_unhandled_members,
1854         g_ir_node_build_typelib): Check all
1855         interface/object/boxed/struct/union members are processed and
1856         abort if they are not. (Mostly callbacks in structs, but also
1857         fields in interfaces.)
1858
1859 2008-10-15  Tommi Komulainen  <tommi.komulainen@iki.fi>
1860
1861         * a/girepository/girnode.c (g_ir_node_build_members,
1862         g_ir_node_build_typelib): refactor common code for processing
1863         members to a function
1864
1865 2008-10-15  Tommi Komulainen  <tommi.komulainen@iki.fi>
1866
1867         * gir/Makefile.am (check-local): check that typelib -> gir -> typelib
1868         transformation is lossless (it's not)
1869
1870 2008-10-15  Tommi Komulainen  <tommi.komulainen@iki.fi>
1871
1872         * tests/Makefile.am: fix tests to compare xml to xml instead of
1873         typelib to xml, and stop on error
1874
1875 2008-10-15  Tommi Komulainen  <tommi.komulainen@iki.fi>
1876
1877         * tools/generate.c (write_type_name, write_type_info,
1878         write_type_info, write_object_info, write_object_info,
1879         write_interface_info, write_error_domain_info): reduce code
1880         duplication
1881
1882 2008-10-15  Tommi Komulainen  <tommi.komulainen@iki.fi>
1883
1884         Bug 556174 – parse types for lists etc.
1885
1886         * girepository/girparser.c (end_type_recurse):
1887         * tests/boxed.gir:
1888         * tools/generate.c (write_type_info, write_field_info,
1889         write_callable_info, write_callable_info, write_constant_info,
1890         write_property_info): use nested <type>s for lists and hashes
1891
1892 2008-10-15  Tommi Komulainen  <tommi.komulainen@iki.fi>
1893
1894         * tests/enum.gir:
1895         * tests/object.gir: remove trailing whitespace from inside
1896         elements to match g-ir-generate output
1897
1898 2008-10-15  Tommi Komulainen  <tommi.komulainen@iki.fi>
1899
1900         * tools/generate.c (xml_printf): quote printf arguments so that
1901         we don't generate invalid XML by writing unescaped double quotes
1902         and such in attributes
1903
1904 2008-10-15  Tommi Komulainen  <tommi.komulainen@iki.fi>
1905
1906         * tools/generate.c (write_field_info, write_callable_info,
1907         write_function_info, write_callback_info, write_struct_info,
1908         write_constant_value, write_signal_info, write_vfunc_info,
1909         write_object_info, write_interface_info, write_union_info,
1910         write_repository): remove unused indent parameters, xmlwriter
1911         keeps track of necessary indentation
1912
1913 2008-10-15  Tommi Komulainen  <tommi.komulainen@iki.fi>
1914
1915         * tools/generate.c (xml_element_new, xml_element_free,
1916         xml_start_element, xml_end_element, xml_end_element_unchecked,
1917         xml_open, xml_close): Keep track of generated XML tree and
1918         handle indentation and closing tags properly.
1919         (write_field_info, write_callable_info, write_function_info,
1920         write_callback_info, write_struct_info, write_value_info,
1921         write_constant_info, write_enum_info, write_signal_info,
1922         write_vfunc_info, write_property_info, write_object_info,
1923         write_interface_info, write_error_domain_info, write_union_info,
1924         write_repository): Use xml_start_element and xml_end_element to
1925         open/close tags.
1926
1927 2008-10-15  Tommi Komulainen  <tommi.komulainen@iki.fi>
1928
1929         * tools/generate.c (xml_printf, xml_open, xml_close, xml_free):
1930         (write_type_name, write_type_info, write_field_info,
1931         write_callable_info, write_function_info, write_callback_info,
1932         write_struct_info, write_value_info, write_constant_value,
1933         write_constant_info, write_enum_info, write_signal_info,
1934         write_vfunc_info, write_property_info, write_object_info,
1935         write_interface_info, write_error_domain_info, write_union_info,
1936         write_repository): wrap all FILE access to go through simple xmlwriter
1937
1938 2008-10-15  Tommi Komulainen  <tommi.komulainen@iki.fi>
1939
1940         Bug 556400 – Fails to build on OS X 10.4
1941
1942         * configure.ac: check for functions backtrace and backtrace_symbols
1943         * girepository/girparser.c (backtrace_stderr): Comment out
1944         implementation if the functions are not available.
1945         * gcov.mak (clean-gcov, clean-gcno): always call 'find' with a
1946         directory for better portability
1947
1948 2008-10-15  Johan Bilien  <jobi@via.ecp.fr>
1949
1950         Bug 556433 – assume direction = out for int * parameters
1951
1952         * giscanner/ast.py: define a list of types for which, if passed as
1953         reference, we assume a default direction of 'out'
1954         * giscanner/transformer.py: if a type has type pointer to one of the
1955         previously defined types, and no direction is set, assume out.
1956         * tests/scanner/drawable.[ch]: added tests for guessed direction=out
1957
1958 2008-10-15  Johan Bilien  <jobi@via.ecp.fr>
1959
1960         * tests/scanner/annotation.c: fixed a few copy-paste errors
1961
1962 2008-10-14  Johan Bilien  <jobi@via.ecp.fr>
1963
1964         Bug 556323 – transfer-ownership is wrong for functions returning const
1965         char *
1966
1967         * giscanner/transformer.py: check for a const string as return value,
1968         not just const char*. Suggested by Colin Walters
1969         * tests/scanner/annotation-1.0-expected.gir: updated expected output
1970
1971 2008-10-14  Johan Bilien  <jobi@via.ecp.fr>
1972
1973         * girepository/ginfo.c, girepository/girepository.h: add
1974         g_union_info_find_method
1975
1976 2008-10-14  Colin Walters  <walters@verbum.org>
1977
1978         * tests/repository/Makefile.am: Reenable repo test.
1979         * tests/repository/gitestrepo.c: Prepend search
1980         path for $(top_builddir)/gir dir so that we don't
1981         require installation for "make check" to pass.
1982
1983 2008-10-13  Jürg Billeter  <j@bitron.ch>
1984
1985         * giscanner/glibtransformer.py:
1986         * tests/scanner/annotation-1.0-expected.gir:
1987         * tests/scanner/drawable-1.0-expected.gir:
1988         * tests/scanner/foo-1.0-expected.gir:
1989         * tests/scanner/utility-1.0-expected.gir:
1990
1991         Support fields in GObject structs
1992
1993 2008-10-13  Jürg Billeter  <j@bitron.ch>
1994
1995         * giscanner/ast.py: add signed integer and off_t to type_names
1996
1997 2008-10-12  Jürg Billeter  <j@bitron.ch>
1998
1999         * giscanner/girparser.py: Parse bits attribute of fields
2000
2001 2008-10-12  Tommi Komulainen  <tommi.komulainen@iki.fi>
2002
2003         * tests/repository/Makefile.am: run 'gitestrepo' in 'make check'
2004         * tests/repository/gitestrepo.c (main): instantiate
2005         'GCancellable' to ensure the GType is registered before using
2006         g_type_from_name()
2007
2008 2008-10-12  Johan Bilien  <jobi@via.ecp.fr>
2009
2010         * giscanner/girparser.py: actually add the parsed constant nodes
2011
2012 2008-10-12  Colin Walters  <walters@verbum.org>
2013
2014         * girepository/girepository.c: Don't cast DirEntry to Blob,
2015         actually look it up by offset.
2016
2017 2008-10-12  Johan Bilien  <jobi@via.ecp.fr>
2018
2019         * giscanner/girparser.py: parse constant nodes in gir files
2020
2021 2008-10-12  Johan Bilien  <jobi@via.ecp.fr>
2022
2023         * giscanner/transformer.py: prefix for constants have an underscore,
2024         so remove them as if they were functions, not objects.
2025
2026 2008-10-12  Johan Bilien  <jobi@via.ecp.fr>
2027
2028         * tests/scanner/foo-1.0-expected.gir: add constants to expected gir
2029         file
2030
2031 2008-10-12  Colin Walters  <walters@verbum.org>
2032
2033         Initial patch from Jani Monoses.
2034
2035         * girepository/gtypelib.c: Fix inverted test for success
2036         in version parsing.
2037
2038 2008-10-12  Tommi Komulainen  <tommi.komulainen@iki.fi>
2039
2040         * tools/generate.c (write_callable_info): use "transfer-ownership"
2041         attribute for return values
2042
2043 2008-10-12  Tommi Komulainen  <tommi.komulainen@iki.fi>
2044
2045         * tools/generate.c (write_callable_info): move "transfer" and
2046         "null-ok" attributes from <function> to <return-value> element
2047
2048 2008-10-12  Tommi Komulainen  <tommi.komulainen@iki.fi>
2049
2050         * girepository/girparser.c (start_return_value): handle
2051         "transfer-ownership" attribute
2052
2053 2008-10-12  Tommi Komulainen  <tommi.komulainen@iki.fi>
2054
2055         * girepository/girparser.c (parse_param_transfer):
2056         * tools/generate.c (write_callable_info): use "container" for
2057         container/shallow ownership transfer (not "shallow")
2058
2059 2008-10-12  Tommi Komulainen  <tommi.komulainen@iki.fi>
2060
2061         * girepository/girparser.c (parse_param_transfer,
2062         start_parameter): Refactor handling of transfer=none/shallow/full
2063         to separate function
2064
2065 2008-10-12  Tommi Komulainen  <tommi.komulainen@iki.fi>
2066
2067         Bug 556048 – Crash in g_irepository_find_by_gtype
2068
2069         * girepository/gtypelib.h (BLOB_IS_REGISTERED_TYPE): added
2070         * girepository/girepository.c (find_interface): Fix
2071         find_by_gtype case to get the type name from right offset
2072
2073 2008-10-12  Jürg Billeter  <j@bitron.ch>
2074
2075         * giscanner/girparser.py: Fix parsing transfer-ownership attribute
2076         of <return-value>
2077
2078 2008-10-12  Tommi Komulainen  <tommi.komulainen@iki.fi>
2079
2080         * girepository/gtypelib.h (RegisteredTypeBlob): make
2081         'unregistered' one bit wide as everywhere else
2082
2083 2008-10-12  Jürg Billeter  <j@bitron.ch>
2084
2085         * giscanner/glibtransformer.py:
2086         * tests/scanner/annotation-1.0-expected.gir:
2087         * tests/scanner/drawable-1.0-expected.gir:
2088         * tests/scanner/drawable.h:
2089         * tests/scanner/foo-1.0-expected.gir:
2090         * tests/scanner/utility-1.0-expected.gir:
2091
2092         Readd class records as workaround to not break Gtk typelib
2093
2094 2008-10-12  Tommi Komulainen  <tommi.komulainen@iki.fi>
2095
2096         * tests/types/Makefile.am: fix typo in gitesttypes namespace
2097
2098 2008-10-12  Jürg Billeter  <j@bitron.ch>
2099
2100         * giscanner/glibtransformer.py: Don't generate <record> elements
2101         for class structs.
2102         * tests/scanner/*: Update test cases
2103
2104 2008-10-11  Colin Walters  <walters@verbum.org>
2105
2106         Bug 552858: versioning
2107
2108         This is a big patch.  You should probably remove your installation
2109         tree to be cleaner.
2110
2111         * docs/typelib-format.txt: Add nsversion entry which holds
2112         version of namespace.
2113         * girepository/girepository.h: Add 'version' parameter to
2114         g_irepository_require.  This may be NULL.  Normally
2115         bindings should pass an explicit version though.
2116         * girepository/girepository.c: Lots of infrastructure to
2117         support versioning.  Add some more documentation.  Disallow
2118         some usage of NULL namespaces.
2119         * girepository/girmodule.c: Add version parameter.
2120         * girepository/gtypelib.c: Update header size.
2121         * giscanner/ast.py: Add version to Namespace.
2122         * giscanner/girparser.py: Parse version attribute from
2123         XML, pass to Namespace.
2124         * giscanner/girwriter.py: Write out version parameter.
2125         * giscanner/transformer.py: Clean up include registration.
2126         * tests/*: Add version attribute.
2127         * tests/invoke/invoke.c: Don't try looking up test before
2128         it's loaded in repository.
2129         * tools/generate.c: Output version parameter.
2130         * gir/Makefile.am: Add 2.0 version to .gir files.
2131
2132 2008-10-11  Colin Walters  <walters@verbum.org>
2133
2134         * giscanner/scannerlexer.l (parse_gtkdoc): Don't lose
2135         if we have mismatched parens.
2136
2137 2008-10-11  Lucas Rocha  <lucasr@gnome.org>
2138
2139         * giscanner/girparser.py (_parse_enumeration_bitfield): fix typo
2140         on 'members' variable.
2141
2142 2008-10-11  Colin Walters  <walters@verbum.org>
2143
2144         Bug 555947 - update annotations syntax
2145
2146         * giscanner/ast.py: Default to None for transfer.  Remove
2147         default transfers for container types; we require this to
2148         be specified now.
2149         * giscanner/girwriter.py: Transfer is now 'none', 'container',
2150         'full' to match repository.
2151         * giscanner/scannerlexer.l: Annotations now are parenthesized.
2152         * giscanner/transformer.py: Update for new annotations syntax.
2153         * tests/*: Update.
2154
2155 2008-10-11  Johan Bilien  <jobi@litl.com>
2156
2157         * giscanner/scannerparser.y: ignore non-UTF-8 string constants
2158
2159 2008-10-11  Johan Bilien  <jobi@litl.com>
2160
2161         Bug 552347: Parse #defines constants
2162
2163         * girepository/gtypelib.c: update the list of value_size
2164         with recently defined type tags
2165         * giscanner/scannerparser.y: brought back parsing of #defined, as
2166         present in older version
2167         * giscanner/giscannermodule.c: bind gi_source_scanner_append_filename
2168         * giscanner/girwriter.py: write out constant tags in the gir
2169         * giscanner/sourcescanner.py: add accessor for const_string
2170         * giscanner/transformer.py, giscanner/glibtransformer.py: handle
2171         constant
2172
2173 2008-10-11  Tommi Komulainen  <tommi.komulainen@iki.fi>
2174
2175         Bug 555946: Install a test module exercising all types, transfer
2176         rules, etc.
2177
2178         * configure.ac
2179         * tests/Makefile.am
2180         * tests/types/*: Add and install a test module that has functions
2181         accepting and returning most of the basic types to enable bindings
2182         implementors to more easily test their type conversion routines.
2183
2184 2008-10-11  Jürg Billeter  <j@bitron.ch>
2185
2186         Bug 552374: Const strings should be identified in the gir.
2187
2188         * giscanner/transformer.py: support string memory management
2189         * tests/scanner/foo.h: use char * and const char *
2190         * tests/scanner/foo-expected.gir: test that
2191
2192 2008-10-11  Johan Dahlin  <johan@gnome.org>
2193
2194         * giscanner/girparser.py:
2195         Also parse enums which are not glib types.
2196
2197 2008-10-11  Lucas Rocha  <lucasr@gnome.org>
2198
2199         Bug 552370: add one more test for unsigned as a type, not as
2200         a type qualifier.
2201
2202         * giscanner/ast.py: add 'uint' type name for 'unsigned'.
2203         * test/scanner/foo.h: add function which uses unsigned as a type.
2204         * test/scanner/foo-expected.gir: test that.
2205
2206 2008-10-11  Andreas Rottmann  <a.rottmann@gmx.at>
2207
2208         Bug 555712: Struct and union issues
2209
2210         * giscanner/scannerparser.y (struct_declarator): Use information
2211         provided about the bit width of a field.
2212         * giscanner/transformer.py (Transformer._create_member): Pass the
2213         symbol's const_int member to the created field (it represents the
2214         bit width).
2215         * giscanner/girwriter.py (GIRWriter._write_field): Output 'bits'
2216         field attribute, if present.
2217         * giscanner/ast.py (Field): Add 'bits' member, specifying the
2218         width in bits of the field (only relevant for bitfields).
2219         * tests/*: Updated.
2220
2221         * giscanner/transformer.py (Transformer._create_typedef_struct)
2222         (Transformer._create_typedef_union): Add calls to _create_struct()
2223         and _create_union(), respectively. This causes the scanner to
2224         generate output for fields of struct and union typedefs.
2225         * tests/*: Updated.
2226
2227 2008-10-11  Jürg Billeter  <j@bitron.ch>
2228
2229         Bug 552370: unsigned not scanned properly
2230
2231         * giscanner/scannerparser.y: combine basic types such as unsigned
2232         int and long long when scanning
2233         * tests/scanner/foo-expected.gir:
2234         * tests/scanner/foo.c: (foo_test_unsigned):
2235         * tests/scanner/foo.h: test that
2236
2237 2008-10-11  Lucas Rocha  <lucasr@gnome.org>
2238
2239         Bug 554854: The --typelib-xml and --inject options should reuse
2240         giscanner parser/writer.
2241
2242         * giscanner/ast.py: add constructor list to Struct and Union.
2243         Add new param in Return's contructor to define transfer.
2244         * giscanner/girparser.py: several additions to the parser in order
2245         to have parsing all nodes of the gir xml files.
2246         * tools/g-ir-scanner (typelib_xml_strip, inject): use gir parser
2247         and writer in --inject and --typelib-xml options.
2248         * giscanner/xmlwriter.py: ignore empty attributes instead of
2249         raising an error as this basically exposes a bug in GIRParser.
2250         This should be reverted as soon as the parser is fixed.
2251
2252 2008-10-11  Lucas Rocha  <lucasr@gnome.org>
2253
2254         Bug 552376: scanner generates wrong names for enum members when
2255         there's no defined gtype.
2256
2257         * giscanner/utils.py (strip_common_prefix): Always strip common
2258         prefix exactly up to the last "_", and not beyond.
2259         * tests/scanner/foo.h (FooEnumNoType): add FOO_ENUM_NEUF. The point
2260         here is that the first character after the last '_' should should be
2261         the same as the character in the same position on the type name.
2262         * tests/scanner/foo-expected.gir: test that
2263
2264 2008-10-10  Lucas Rocha  <lucasr@gnome.org>
2265
2266         Bug 555293: append library_paths to LPATH env variable to work
2267         around a bug in find_library when using ldconfig.
2268
2269         * tools/g-ir-scanner (main): ditto.
2270
2271 2008-10-09  Lucas Rocha  <lucasr@gnome.org>
2272
2273         * girepository/girepository.c (register_internal): fix regression on
2274         invoke test case by making sure we load the global module in the
2275         typelib when dealing with inline typelibs.
2276         * girepository/gtypelib.c: a couple of coding style fixes.
2277
2278 2008-10-06  Lucas Rocha  <lucasr@gnome.org>
2279
2280         Bug 555294: Add support for multiple shared libraries per typelib.
2281
2282         * girepository/ginvoke.c (g_function_info_invoke),
2283         girepository/ginfo.c(g_registered_type_info_get_g_type): use
2284         g_typelib_symbol instead of g_module_symbol.
2285         * girepository/girepository.h: remove g_typelib_set_module and add
2286         g_typelib_symbol.
2287         * girepository/gtypelib.[ch] (find_some_symbol, _g_typelib_init,
2288         g_typelib_new_from_memory, g_typelib_new_from_const_memory,
2289         g_typelib_free, g_typelib_symbol): chnage GTypeLib to hold a list of
2290         modules instead of just one. The symbol lookup is now abstracted
2291         behind g_typelib_symbol which tries to find the passed symbol name in
2292         one of its modules.
2293         * giscanner/girwriter.py, tools/g-ir-scanner: change scanner to read
2294         and write shared_library attribute as a comma-separated list of libs.
2295
2296 2008-10-06  Colin Walters  <walters@verbum.org>
2297
2298         * giscanner/transformer.py: Parse length= annotation as
2299         a parameter name, not a raw int.
2300         * tests/*: Update.
2301
2302 2008-10-03  Colin Walters  <walters@verbum.org>
2303
2304         Bug 551744: Non-GObject types aren't aggregating ctors and methods
2305
2306         * girepository/gtypelib.c: Allow ctors/methods on struct,union,
2307         and boxed.
2308         * giscanner/glibtransformer.py: Ditto, and GLibBoxed is also a
2309         registered type.
2310         * tests/*: Extend.
2311
2312 2008-10-03  Colin Walters  <walters@verbum.org>
2313
2314         Bug 554576: scan problem with ev_selection_render_selection()
2315
2316         * giscanner/transformer.py: Only do type resolution once we've
2317         scanned all types.  What could happen before is that we'd strip
2318         the namespace from local type "EvSelection" => Selection, and
2319         then later pull a "Selection" from some other namespace because
2320         we hadn't yet seen the local EvSelection.  This could come
2321         down to hash table ordering and other things so not easy
2322         to write a test for.
2323
2324 2008-10-03  Lucas Rocha  <lucasr@gnome.org>
2325
2326         * giscanner/girwriter.py (_parser_member): fix the last parameter of
2327         GLibEnumMember constructor as it should be the enum member nick.
2328
2329 2008-10-02  Colin Walters  <walters@verbum.org>
2330
2331         Bug 552961: remove this parameter for methods
2332
2333         * giscanner/glibtransformer.py: Delete this parameter; it is
2334         redundant.
2335         * girepository/ginvoke.c: Insert this parameter for methods.
2336         * girepository/gtypelib.c: Remove no longer needed verification of
2337         method this parameter.
2338         * tests/*: Update.
2339
2340 2008-09-30  Dan Winship  <danw@gnome.org>
2341
2342         Bug 554490: g-ir-scanner gets confused by '\\'
2343
2344         * giscanner/scannerlexer.l (chartext, stringtext): fix use of
2345         backslashes so it will correctly parse '\\' and "\\"
2346
2347         * tests/scanner/annotation.c: add a use of '\\' to make sure that
2348         this stays fixed
2349
2350         * giscanner/glibtransformer.py (GLibTransformer.count_type): typo
2351
2352 2008-10-02  Colin Walters  <walters@verbum.org>
2353
2354         bug 552393: Note variadic functions
2355
2356         * giscanner/scannerparser.y: Parse ellipsis.  Refactor grammar
2357         to use parameter_list directly.
2358         * giscanner/sourcescanner.h: Add ellipsis csymbol type.
2359         * giscanner/ast.py: Add Varargs type.
2360         * giscanner/transformer.py: Check for ellipsis symbol, transform
2361         to varargs type.
2362         * girepository/girnode.h: Add varargs flag to in-memory nodes.
2363         Parse varargs functions, but filter them out before we start
2364         compiling the typelib.
2365
2366 2008-10-02  Colin Walters  <walters@verbum.org>
2367
2368         Bug 554632: type tag for GType
2369
2370         * girepository/girepository.h, girepository/girepository.c:
2371         Add type tag for GType - it's a special type we don't want
2372         to resolve to just "long".
2373         * docs/typelib-format.txt: Update.
2374         * girepository/girparser.c: Parse it.
2375         * giscanner/glibtransformer.py: Ensure we don't put GType in
2376         the GObject.gir.
2377         * tools/generate.c: Remove hardcoded type list.
2378         * test/* update.
2379
2380 2008-09-30  Dan Winship  <danw@gnome.org>
2381
2382         Bug 554521: scanner generates wrong names for enum members with
2383         full type name prefix
2384
2385         * giscanner/utils.py (strip_common_prefix): Fix this to strip the
2386         right amount when the entire "first" string is a prefix of
2387         "second"
2388
2389         * tests/scanner/foo.h (FooEnumFullname):
2390         * tests/scanner/foo-expected.gir: test that
2391
2392 2008-09-29  Colin Walters  <walters@verbum.org>
2393
2394         Bug 552380: Array parameters should be marked in the gir
2395
2396         * giscanner/ast.py: Default char** to utf8[], and guchar* to
2397         uint8[].  Add Array, List, and Map subclasses of Type;
2398         these types can be generic.  Return transfer defaults
2399         to true if return value is string or container type.
2400         Delete Sequence type.
2401         * giscanner/scannerlexer.l: Syntax change for annotations;
2402         use <> since it's more readable.
2403         * giscanner/girwriter.py: Write out these changes.
2404         * giscanner/girparser.py: Parse them.
2405         * giscanner/transformer.py: Have a defined set of
2406         both list and map types.  When creating a type,
2407         check if the ctype we've parsed is one of them,
2408         if so create a container type subclass as appropriate.
2409         * girepository/girparser.c: Parse in generic types.
2410         * tests/*: Update.
2411
2412 2008-09-27  Colin Walters  <walters@verbum.org>
2413
2414         * tools/g-ir-scanner: Add --inject option.
2415
2416 2008-09-25  Colin Walters  <walters@verbum.org>
2417
2418         Remove non-repository types from GIR
2419
2420         * giscanner/ast.py: The canonical name is 'utf8', not
2421         'string'.
2422         * giscanner/glibast.py: A few more glib type mappings.
2423         * girepository/girparser.c: We only parse repository types.
2424         * tests/*.gir: Update.
2425
2426 2008-09-23  Colin Walters  <walters@verbum.org>
2427
2428         Bug 552566: Add time_t type
2429
2430         We need a type for time_t since it's special in C, and just
2431         mapping it to long precluded bindings from handling it
2432         in a nice way.
2433
2434 2008-09-19  Colin Walters  <walters@verbum.org>
2435
2436     Bug 552390: Handle capitialization like "DBus" more robustly
2437
2438     The to_underscores function was designed for use against prefixed
2439     names; we need a separate function which will convert names like
2440     DBusFoo into dbus_foo, not d_bus_foo.
2441
2442 2008-09-19  Colin Walters  <walters@verbum.org>
2443
2444     Add check to make sure we're not hitting out unresolved types
2445
2446     Validate the "this" argument for methods
2447
2448     Remove heuristic matching of methods to classes based on prefix
2449
2450     It was a broken hack that dated from when we handled underscoring
2451     and capitalization conventions less well.
2452
2453 2008-09-18  Colin Walters  <walters@verbum.org>
2454
2455     Bug 552384: Use SHLIB_SUFFIX intead of G_MODULE_SUFFIX for Darwin
2456
2457     On Darwin, the suffix for installed shared libraries (.dylib) is
2458     different from loadable modules (.so).  We use a bit of magic shell
2459     script from Behdad Esfahbod to figure out the right suffix.
2460
2461 2008-09-15  Johan Dahlin  <johan@gnome.org>
2462
2463         * giscanner/sourcescanner.py (SourceType.type_qualifier): Add
2464         a wrapper for type_qualifier as well.
2465
2466 2008-09-15  Colin Walters  <walters@verbum.org>
2467
2468         http://bugzilla.gnome.org/show_bug.cgi?id=552065
2469
2470         * giscanner/ast.py: Add deprecation attributes.
2471         * giscanner/girwriter.py: Write out deprecation data.
2472         * girepository/girparser.c: Relax parsing; deprecated
2473         attribute now includes freeform string.
2474         * giscanner/scannerlexer.l: Parse Deprecated.
2475         * giscanner/transformer.py: Look for deprecated attribute
2476         on functions.
2477         * tests/scanner/*: Add a Deprecated test.
2478
2479 2008-09-14  Tor Lillqvist  <tml@novell.com>
2480
2481         * tests/scanner/Makefile.am (%.typelib): Use $(EXEEXT).
2482
2483 2008-09-14  Colin Walters  <walters@verbum.org>
2484
2485         * giscanner/glibtransformer.py: Ignore functions with
2486         leading _.
2487
2488 2008-09-12  Colin Walters  <walters@verbum.org>
2489
2490         * giscanner/glibtransformer.py: Accept Gtk.Type as GType.
2491
2492 2008-09-12  Colin Walters  <walters@verbum.org>
2493
2494         * giscanner/ast.py: Bind pid_t to INT for vte.
2495
2496 2008-09-12  Colin Walters  <walters@verbum.org>
2497
2498         * giscanner/girparser.py: Parse c:type for boxed records/unions.
2499         * giscanner/glibast.py: Avoid overwriting ctype.
2500         * giscsanner/transformer.py: Try resolving types using the GType names.
2501
2502 2008-09-12  Colin Walters  <walters@verbum.org>
2503
2504         * giscanner/minixpath.py: Code to run an "XPath"
2505         assertion against an XML tree, taken from
2506         gir-repository/gir/tests.py.
2507         * giscanner/Makefile.am: Ship it.
2508         * tools/g-ir-scanner: Add --xpath-assertions option.
2509         * gir/GLib-assertions.txt: Add a few assertions.
2510         * gir/Makefile.am: Run them.
2511
2512 2008-09-11  Colin Walters  <walters@verbum.org>
2513
2514         http://bugzilla.gnome.org/show_bug.cgi?id=551737
2515
2516         * giscanner/transformer.py: Fix strip_namespace_func to only strip
2517         prefix if it ends with _.  Tweak callback stripping to determine
2518         based on presence of _ whether we need to use strip_namespace_func
2519         or strip_namespace_object.
2520
2521 2008-09-09  Owen Taylor  <otaylor@redhat.com>
2522
2523         * docs/typelib-format.txt: Wether => Whether
2524
2525 2008-09-08  Colin Walters  <walters@verbum.org>
2526
2527         * girepository/girparser.c: Default to "readable" for properties.
2528         * giscanner/ast.py: Add readable, writable etc.
2529         * giscanner/girwriter.py: Writ them.
2530         * giscanner/glibtransformer.py: Inspect them.
2531         * tests/*: Update.
2532
2533 2008-09-07  Colin Walters  <walters@verbum.org>
2534
2535         * giscanner/cgobject.py: Add comment.
2536
2537 2008-09-07  Colin Walters  <walters@verbum.org>
2538
2539         * giscanner/cgobject.py: Also call g_thread_init.
2540
2541 2008-09-07  Colin Walters  <walters@verbum.org>
2542
2543         * giscanner/transformer.py: Fix regression by not
2544         stripping prefix before stripping namespace for unions
2545         either.
2546
2547 2008-09-06  Colin Walters  <walters@verbum.org>
2548
2549         * giscanner/transformer.py: If a namespace contains
2550         multiple caps, try stripping both gnomekeyring_ and
2551         gnome_keyring_.
2552
2553 2008-09-07  Johan Dahlin  <johan@gnome.org>
2554
2555         Bug 551162 – giscanner does not recognize asm and __asm__
2556         * giscanner/scannerlexer.l:
2557         Patch by Jani Monoses.
2558
2559 2008-09-06  Colin Walters  <walters@verbum.org>
2560
2561         * girepository/girnode.c: Allow gtype_name
2562         and gtype_init in struct and union.
2563         * girepository/girparser.c: Parse glib:
2564         boxed bits for both structure and union.
2565         * girepository/gtypelib.c: Don't barf
2566         if structure is boxed.
2567         * giscanner/girparser.py: Parse new XML
2568         format.
2569         * giscanner/girwriter.py: Write out new
2570         XML format.
2571         * giscanner/glibast.py: Define new classes
2572         which are both Boxed and Struct/Union, as
2573         well as an "Other" for everything else.
2574         * giscanner/glibtransformer.py: Handle
2575         boxed types specially; we try to merge
2576         them with a struct/union if one exists,
2577         otherwise fall back to generic boxed.
2578         * tests/*: Update.
2579         * tools/generate.c: Write out new format.
2580
2581 2008-09-06  Johan Dahlin  <johan@gnome.org>
2582
2583         * giscanner/grealpath.h: Include stdlib.h
2584
2585         * docs/g-ir-generate.1: Remove leading %
2586
2587 2008-09-01  Colin Walters  <walters@verbum.org>
2588
2589         * girepository/girparser.c: Look at c:type to determine
2590         whether or not an item is a pointer.
2591
2592 2008-09-01  Johan Dahlin  <johan@gnome.org>
2593
2594         * tests/scanner/Makefile.am:
2595         Set PYTHONPATH so the scanner can run
2596         even if you didn't install anything.
2597
2598 2008-09-01  Johan Dahlin  <johan@gnome.org>
2599
2600         * configure.ac:
2601         Post-release version bump
2602
2603 === 0.5.0 ===
2604 2008-09-01  Johan Dahlin  <johan@gnome.org>
2605
2606         * NEWS: Update
2607
2608 2008-08-31  Colin Walters  <walters@verbum.org>
2609
2610         * giscanner/glibtransformer.py: Quiet info
2611         prints for now.
2612
2613 2008-08-31  Johan Dahlin  <johan@gnome.org>
2614
2615         * configure.ac:
2616         Bump version to 0.5.0
2617
2618 2008-08-31  Colin Walters  <walters@verbum.org>
2619
2620         * giscanner/glibtransformer.py: Follow aliases to ensure
2621         we don't get a constructor returning a basic type.
2622         * giscanner/transformer.py: Add function to follow aliases.
2623         * tests/ Update.
2624
2625 2008-08-31  Johan Dahlin  <johan@gnome.org>
2626
2627         * giscanner/scannerlexer.l:
2628         * giscanner/scannerparser.y:
2629         * giscanner/sourcescanner.h:
2630         * giscanner/sourcescanner.py:
2631         Parse GCC extensions in the parser instead of just undeffing them
2632         in the pre-processor.
2633
2634 2008-08-31  Johan Dahlin  <johan@gnome.org>
2635
2636         * giscanner/glibtransformer.py:
2637         Clean up a huge if. Do not add methods or constructors
2638         to enums/flags.
2639         * giscanner/utils.py:
2640         second might be longer than first, check that.
2641
2642 2008-08-31  Johan Dahlin  <johan@gnome.org>
2643
2644         * gir/Makefile.am:
2645         Add a GModule.gir
2646
2647 2008-08-31  Colin Walters  <walters@verbum.org>
2648
2649         * girepository/girparser.c: Don't lose if we
2650         have no includedirs
2651
2652 2008-08-31  Colin Walters  <walters@verbum.org>
2653
2654         * giscanner/glibtransformer.py: Look for libtool
2655         library in current directory
2656         * tests/scanner - Update.
2657
2658 2008-08-30  Colin Walters  <walters@verbum.org>
2659
2660         * docs/typelib-format.txt: Add a guint32
2661         for dependencies.
2662         * gir/Makefile.am: Dep on Makefile
2663         * girepository/ginfo.c:
2664         * girepository/girepository.c: Clean up
2665         default typelib handling; remove global
2666         default_typelib variable.  Ensure we handle
2667         NULL repository in more places.
2668         Support dependency resolution.
2669         Support lazy loading.
2670         * girepository/girepository.h: Remove
2671         g_irepository_unregister; we don't support
2672         unloading typelibs since really they're
2673         process-global.  Update for lazy loading
2674         API.
2675         * girepository/girmodule.c: Use g_new0.
2676         Add dependencies to GirModule.
2677         * girepository/girparser.c: Parse dependencies.
2678         * girepository/gtypelib.c: Add 4 bytes for
2679         dependencies.
2680         * tests/Makefile.am: Kill off gobject.gir,
2681         it conflicts with the real one.
2682         * tests/object.gir: Dep on GObject.
2683         * tools/generate.c: Take --includedir
2684         argument to say which directories to search
2685         for typelibs.  Print out dependencies.
2686
2687 2008-08-30  Colin Walters  <walters@verbum.org>
2688
2689         * giscanner/glibtransformer.py: Reduce warning noise.
2690
2691 2008-08-29  Colin Walters  <walters@verbum.org>
2692
2693         * girepository/ginfo.c: Add some assertions regarding
2694         refcounts, just to be sure.
2695         * giscanner/glibtransformer.py: Blacklist a few more
2696         odd Gio methods.
2697
2698 2008-08-29  Colin Walters  <walters@verbum.org>
2699
2700         * giscanner/glibtransformer.py: Blacklist a few
2701         functions that use GError oddly
2702
2703 2008-08-29  Colin Walters  <walters@verbum.org>
2704
2705         * girepository/gtypelib.c: Don't crash if no
2706         shlib is embedded
2707
2708 2008-08-29  Colin Walters  <walters@verbum.org>
2709
2710         * girepository/girparser.c: Handle chains of aliases
2711         across modules by ensuring we fully qualify aliases
2712         from includes.
2713
2714 2008-08-29  Colin Walters  <walters@verbum.org>
2715
2716         * girepository/girparser.c: Don't search aliases
2717         for basic types.
2718
2719 2008-08-29  Colin Walters  <walters@verbum.org>
2720
2721         * girepository/girparser.c: Rewrite type parsing
2722         to handle both GLib parsing case as well as correctly
2723         handling GLib.List and friends.  Don't try to treat
2724         e.g. ListStore as a List.
2725
2726 2008-08-29  Colin Walters  <walters@verbum.org>
2727
2728         * girepository/gtypelib.c: Add more context
2729         during validate.
2730
2731 2008-08-29  Colin Walters  <walters@verbum.org>
2732
2733         * giscanner/glibtransformer.py: Add some informative
2734         logging messages in corner cases.  Be sure we use
2735         the most recent node set instead of a cache
2736         when generating result set.
2737         * tests/: Remove duplicated bits in expected girs
2738         * girepository/girparser.c: Accept both List (for
2739         compiling GLib) and GLib.List (what the scanner
2740         generates).
2741         * tests/ - Update.
2742         * tools/generate.c: Generate canonical form.
2743
2744 2008-08-29  Johan Dahlin  <johan@gnome.org>
2745
2746         * giscanner/config.py.in:
2747         Use datarootdir instead of datadir to avoid
2748         an autoconf warning.
2749
2750 2008-08-29  Johan Dahlin  <johan@gnome.org>
2751
2752         * README:
2753         * TODO:
2754         * examples/gdk-pixbuf.gidl:
2755         * libffi.pc.in:
2756         Update and remove old cruft.
2757
2758 2008-08-29  Johan Dahlin  <johan@gnome.org>
2759
2760         * Makefile.am:
2761         * docs/g-ir-compiler.1:
2762         * docs/g-ir-generate.1:
2763         * docs/g-ir-scanner.1:
2764         Add man pages for the generator and compiler.
2765
2766 2008-08-29  Johan Dahlin  <johan@gnome.org>
2767
2768         * docs/g-ir-scanner.1: Document
2769
2770         * giscanner/Makefile.am:
2771         * giscanner/gidlparser.py:
2772         * giscanner/gidlwriter.py:
2773         * tools/g-ir-scanner:
2774         Remove gidl support.
2775
2776 2008-08-28  Colin Walters  <walters@verbum.org>
2777
2778         * tests/scanner/Makefile.am: Pass the right
2779         --includedir args.  Add a Makefile dep.
2780         * tools/compiler.c: Pass includedirs down.
2781         * girepository/girparser.c: Actually put
2782         includedirs in context, pass down.  Fix
2783         locate_gir.
2784
2785 2008-08-28  Colin Walters  <walters@verbum.org>
2786
2787         * gir/Makefile.am: Use --includedir
2788         * girepository/girparser.c: Recursively parse
2789         includes to pull in aliases and expand them.
2790         We need this to avoid putting unknown names in
2791         the typelibs.
2792         * tools/compiler.c: Add --includedir option.
2793         * giscanner/ast.py: Map size/ssize to types
2794         too.
2795
2796 2008-08-28  Tor Lillqvist  <tml@novell.com>
2797
2798         Make check now runs successfully on Windows.
2799
2800         * tools/compiler.c (write_out_typelib): Use binary mode for output
2801         file on Windows.
2802
2803         * girepository/girnode.c: Don't print NULL strings.
2804
2805         * tests/invoke/Makefile.am
2806         * tests/scanner/Makefile.am: Use -no-undefined on Windows to
2807         convince libtool to build shared libraries.
2808
2809         * tests/invoke/invoke.c: Don't needlessly include <dlfcn.h>. Use
2810         g_assert() instead of printing out expected errors.
2811
2812 2008-08-28  Tor Lillqvist  <tml@novell.com>
2813
2814         * girepository/gtypelib.h: Change type of bitfield fields from
2815         guint to the most suitable smaller type. This makes the struct
2816         sizes match the ones on Linux that the sanity check expects when
2817         using gcc -mms-bitfields on Windows.
2818
2819 2008-08-28  Johan Dahlin  <johan@gnome.org>
2820
2821         * Makefile.am:
2822         * configure.ac:
2823         * gir/Makefile.am:
2824         * giscanner/Makefile.am:
2825         * tests/Makefile.am:
2826         * tests/scanner/Makefile.am:
2827         Make distcheck pass.
2828
2829 2008-08-27  Johan Dahlin  <johan@gnome.org>
2830
2831         * giscanner/Makefile.am:
2832         Only send in -no-undefined on Win32 as it breaks on MacOS X.
2833
2834 2008-08-27  Tor Lillqvist  <tml@novell.com>
2835
2836         Make g-ir-scanner work on Windows. Still problems with the typelib
2837         code. Changes okayed by jdahlin.
2838
2839         * configure.ac: Check for Windows, set Automake conditional
2840         OS_WIN32. Change backslashes to forward slashes in pyexecdir to
2841         avoid shell quoting issues
2842         
2843         * girepository/Makefile.am: Use -no-undefined so that libtool
2844         agrees to build a shared library on Windows.
2845
2846         * girepository/girparser.c (backtrace_stderr): No backtrace() on
2847         Windows. Empty implementation on Windows so far.
2848
2849         * girepository/gtypelib.c (g_typelib_check_sanity): Give more
2850         informative error message for the assertion failures. Tell also
2851         what the expected size of the struct is. Check all sizes first and
2852         fail afterwards if at least one size was different from expected.
2853
2854         * tools/Makefile.am: Reorder libraries into proper logical
2855         dependency order.
2856
2857         * tools/generate.c: Don't include <dlfcn.h>, not used.
2858
2859         * giscanner/Makefile.am: On Windows, link with the Python library,
2860         and install the module DLL as _giscanner.pyd. Remove the
2861         unnecessary import library and libtool library that libtool has
2862         installed.
2863
2864         * giscanner/scannerlexer.l: Recognize the gcc __attribute__ syntax
2865         and just skip it. Recognize also two "l" suffixes for long long
2866         constants. Recognize also __inline__.
2867
2868         * giscanner/grealpath.h (g_realpath): Implement on Windows, using
2869         GetFullPathName(). As such, GetFullPathName() does more than the
2870         UNIX realpath(). It also changes relative paths into absolute
2871         paths. But for our purposes that shouldn't matter.
2872
2873         * giscanner/giscannermodule.c (pygi_source_scanner_parse_file): On
2874         Windows the file descriptor passed to us is from Python. Python
2875         Python2.5 uses the msvcr71.dll C library, while mingw-built code
2876         uses msvcrt.dll. On Windows, file descriptors are specific to
2877         which C library is used. So we must find out what underlying OS
2878         handle corresponds to the file descriptor Python passes us, and
2879         then make that into a file descriptor valid for the C library this
2880         code uses.
2881
2882         * giscanner/sourcescanner.py (_parse): Don't need to bypass
2883         __attribute__ as the lexer now handles it. The definition as empty
2884         was ineffective for mingw anyway, as mingw's _mingw.h undefines
2885         __attribute__. Close the temp file before unlinking it.
2886
2887         * giscanner/cgobject.py: Use correct library name for the gobject
2888         DLL on Windows.
2889
2890         * gir/Makefile.am: Must pass the full basename of the DLLs on
2891         Windows to g-ir-scanner. It's a bit ugly that we have to "know"
2892         that the names of the GLib DLLs are like libglib-2.0-0.dll, but in
2893         reality they won't change, until there is a GLib 3, and then also
2894         the Unix code here needs changing.
2895
2896         Must pass CPPFLAGS to g-ir-scanner when building GLib.gir so that
2897         libintl.h is found.
2898
2899 2008-08-26  Colin Walters  <walters@verbum.org>
2900
2901         * girepository/girepository.c: Search
2902         $DATADIR/girepository instead of
2903         $DATADIR/gitypelibs; this naming makes
2904         it clearer that e.g. jgir can install
2905         .jars there.
2906         * gir/Makefile.am: Install there.
2907
2908 2008-08-26  Colin Walters  <walters@verbum.org>
2909
2910         * girepository/gtypelib.c (_g_typelib_init): Also
2911         use G_MODULE_SUFFIX instead of hardcoding .so.
2912
2913 2008-08-26  Colin Walters  <walters@verbum.org>
2914
2915         * girepository/gtypelib.c (_g_typelib_init): Free
2916         string in the right place.
2917
2918 2008-08-26  Colin Walters  <walters@verbum.org>
2919
2920         * girepository/gtypelib.c (_g_typelib_init): Handle
2921         both .la and .so names; this works better in the
2922         uninstalled library case.
2923
2924 2008-08-26  Johan Dahlin  <johan@gnome.org>
2925
2926         * gir/Makefile.am:
2927         * giscanner/Makefile.am:
2928         * giscanner/cgobject.py:
2929         * giscanner/config.py.in:
2930         * giscanner/sourcescanner.py:
2931         Avoid undeffing __GNUC__, instead define
2932         __attribute__ & friends. Remove glibconfig.h hack.
2933         This makes gobject-introspection work better on
2934         MacOS X, Thanks to Richard Hult for kind help.
2935
2936 2008-08-25  Colin Walters  <walters@verbum.org>
2937
2938         * giscanner/glibtransformer.py: Always print
2939         statistics.
2940
2941 2008-08-25  Colin Walters  <walters@verbum.org>
2942
2943         * giscanner/glibtransformer.py: Skip over
2944         interfaces we don't know.
2945
2946 2008-08-25  Colin Walters  <walters@verbum.org>
2947
2948         * girepository/girparser.c: Parse new implements
2949         syntax, drop gapi one.
2950         * tests/object.gir: Update.
2951         * tools/generate.c: Generate new syntax.
2952
2953 2008-08-25  Colin Walters  <walters@verbum.org>
2954
2955         * giscanner/ast.py: Add interfaces property
2956         to class.
2957         * giscanner/girwriter.py: Write out implemented
2958         interfaces.
2959         * giscanner/glibtransformer.py: Introspect
2960         implemented interfaces.
2961         * tests/scanner/*: Make FooObject implement
2962         FooInterface.
2963
2964 2008-08-25  Colin Walters  <walters@verbum.org>
2965
2966         * giscanner/glibtransformer.py: More correctly pair
2967         methods; if we have a symbol that starts with
2968         e.g. hippo_canvas look for a matching HippoCanvas
2969         class before accepting e.g. HippoCanvasImage.
2970
2971 2008-08-24  Colin Walters  <walters@verbum.org>
2972
2973         * tools/g-ir-scanner: Filter out unknown options from
2974         pkg-config files.
2975
2976 2008-08-24  Colin Walters  <walters@verbum.org>
2977
2978         * giscanner/glibtransformer.py: Fail with better
2979         error if we can't find library.
2980
2981 2008-08-24  Colin Walters  <walters@verbum.org>
2982
2983         * tools/g-ir-scanner: Use subprocess instead of
2984         commands, works on Windows and avoids the evil
2985         shell on Unix.
2986
2987 2008-08-24  Colin Walters  <walters@verbum.org>
2988
2989         * giscanner/glibtransformer.py: Skip over
2990         g_object_get_type from GLib trunk.
2991
2992 2008-08-24  Colin Walters  <walters@verbum.org>
2993
2994         * girepository/girepository.c (g_irepository_require): 
2995         Don't open shared library here; we already do it
2996         in gtypelib.c.
2997
2998 2008-08-24  Colin Walters  <walters@verbum.org>
2999
3000         * girepository/gtypelib.c: Add context stack so
3001         when we get an error we can print out nicely
3002         where it is.
3003
3004 2008-08-24  Johan Dahlin  <johan@gnome.org>
3005
3006         * girepository/girparser.c (start_glib_boxed), (start_function),
3007         (start_field), (start_alias):
3008         Refactor a couple of parsing functions to be simpler to follow.
3009         Avoid huge ifs.
3010
3011 2008-08-24  Johan Dahlin  <johan@gnome.org>
3012
3013         * girepository/girparser.c (start_function):
3014         Remove left-over code, checking type of function.
3015
3016 2008-08-23  Colin Walters  <walters@verbum.org>
3017
3018         * giscanner/config.py: Define DATADIR.
3019         * giscanner/transformer.py: Look in DATADIR.
3020
3021 2008-08-23  Colin Walters  <walters@verbum.org>
3022
3023         * girepository/gtypelib.c: Check constructor
3024         returns.
3025         * girepository/girnode.c: Small tweaks.
3026         * girepository/ginfo.c: Calculate signature offsets
3027         more robustly.
3028         * girepository/girparser.c: Remove duplicate
3029         start_boxed.
3030         * giscanner/glibtransformer.py: Avoid marking
3031         functions which return a basic type as
3032         constructors.
3033
3034 2008-08-23  Colin Walters  <walters@verbum.org>
3035
3036         * girepository/girparser.c: Ignore <include>.
3037         * giscanner/girparser.py: Parse them.
3038         * giscanner/girwriter.py: Generate them.
3039         * giscanner/transformer.py: Process <include>
3040         recursively.  Don't require full path for
3041         includes, look in {$XDG_DATA_DIRS}/gir.
3042         * tools/g-ir-scanner: Pass through includes.
3043         * Makefile.am: Remove extra --include
3044         args for scanner.
3045         * *-expected.gir: Add expected includes.
3046
3047 2008-08-23  Johan Dahlin  <johan@gnome.org>
3048
3049         * tests/scanner/Makefile.am:
3050         * tests/scanner/annotation-expected.gir:
3051         * tests/scanner/drawable-expected.gir:
3052         Avoid duplication in the Makefile, regenerate with new
3053         namespaces (same as the filename)
3054
3055 2008-08-22  Colin Walters  <walters@verbum.org>
3056
3057         * girepository/girnode.c: Don't hardcode integers,
3058         use GITypeTag.
3059
3060 2008-08-22  Johan Dahlin  <johan@gnome.org>
3061
3062         * giscanner/sourcescanner.py:
3063         Check for ../gobject-introspection-1.0.pc.in to determine
3064         if we run installed or uninstalled.
3065
3066 2008-08-22  Johan Dahlin  <johan@gnome.org>
3067
3068         * gir/Makefile.am:
3069         * giscanner/sourcescanner.py:
3070         Send in undefs/defines via writing it directly to stdin
3071         of cpp instead of via arguments.
3072
3073 2008-08-22  Colin Walters  <walters@verbum.org>
3074
3075         * tools/generate.c, tools/compiler.c: Default
3076         to --raw.
3077         * all Makefile.am: Update.
3078
3079 2008-08-22  Colin Walters  <walters@verbum.org>
3080
3081         * girepository/girparser.c: Pass through
3082         recursive types.  Avoid overwriting errors.
3083         * giscanner/xmlwriter.py: Always write the
3084         XML header.
3085         * tests/*.gir: Adjust.
3086         * tests/scanner/Makefile.am: Build typelibs,
3087         and generate XML from those.  Once we
3088         have a good diff mechanism...
3089         * tests/scanner/*-expected.gir: Add XML
3090         header.
3091         * tools/g-ir-scanner: Accept --typelib-xml
3092         option.
3093         * tools/generate.c: Better defaults for transfer.
3094
3095 2008-08-22  Johan Dahlin  <johan@gnome.org>
3096
3097         * configure.ac:
3098         * gir/Makefile.am:
3099         * giscanner/Makefile.am:
3100         * giscanner/config.py.in:
3101         * giscanner/sourcescanner.py:
3102         Use the generated glibconfig.h for all scanner invokations.
3103         Rename it to glibconfig-scanner.h and install it.
3104         Add a config.py which so far contains the include dir.
3105
3106 2008-08-22  Johan Dahlin  <johan@gnome.org>
3107
3108         * gir/Makefile.am:
3109         Replace glibconfig.h with our own, do some replacement
3110         for CPP/C features we do not support
3111
3112 2008-08-22  Colin Walters  <walters@verbum.org>
3113
3114         * tools/generate.c (write_callable_info): Fix unref
3115         sequence.
3116
3117 2008-08-22  Colin Walters  <walters@verbum.org>
3118
3119         * gobject-introspection-1.0.pc.in: Add g-ir-generate.
3120         * tests/Makefile.am: Support $(DEBUG)
3121         * tools/generate.c: Do immediate close tags if no
3122         sub-elements.
3123
3124 2008-08-21  Colin Walters  <walters@verbum.org>
3125
3126         * tests/scanner/drawable-expected.gir,
3127         * tests/scanner/drawable.c,
3128         * tests/scanner/drawable.h:
3129         Add a method.
3130
3131 2008-08-21  Colin Walters  <walters@verbum.org>
3132
3133         * giscanner/glibtransformer.py: Compute prefix
3134         by searching through the symbol for bits
3135         rather than going directly from ctype; this fixes
3136         webkit_ namespace.
3137
3138 2008-08-21  Colin Walters  <walters@verbum.org>
3139
3140         * giscanner/glibtransformer.py: Also try squashing
3141         underscores from namespace, fixes webkit_web_view_new.
3142
3143 2008-08-21  Colin Walters  <walters@verbum.org>
3144
3145         * giscanner/glibtransformer.py: More ctor work,
3146         avoid having gtk_window_group_new end up under
3147         GtkWindow.
3148
3149 2008-08-21  Colin Walters  <walters@verbum.org>
3150
3151         * giscanner/glibtransformer.py: Much simpler approach
3152         of mapping uscored names to classes.
3153         * giscanner/utils.py: Remove unnecessary function.
3154
3155 2008-08-21  Johan Dahlin  <johan@gnome.org>
3156
3157         * girepository/girepository.c (g_irepository_require):
3158         Plug memory leak and avoid using freed memory.
3159         Resolve the whole module path, here as well.
3160
3161 2008-08-21  Colin Walters  <walters@verbum.org>
3162
3163         * giscanner/glibtransformer.py: Look up all permutations
3164         of class names when scanning methods/ctors based on
3165         the prefix instead of using the return value.  This
3166         associates gtk_window_new with the right class.
3167
3168 2008-08-21  Colin Walters  <walters@verbum.org>
3169
3170         * girepository/girmodule.c (g_ir_module_build_typelib): 
3171         Revert change to increment header_size; we do that in
3172         write_string.
3173
3174 2008-08-21  Colin Walters  <walters@verbum.org>
3175
3176         * girepository/girnode.c (write_string): Tweak to
3177         use UINT instead of INT.  Not likely to matter.
3178         * girepository/girmodule.c (g_ir_module_build_typelib):
3179         Add to header_offset as well for header strings
3180         to match what write_string does.
3181         * girepository/gtypelib.c: Replace is_name with
3182         validate_name, which more strongly validates and
3183         handles errors in a better way.  Update all callers.
3184         * giscanner/glibtransformer.py: Handle constructors
3185         better.
3186
3187 2008-08-21  Johan Dahlin  <johan@gnome.org>
3188
3189         * gir/Makefile.am (typelibs_DATA): Build and 
3190         install the Gio.typelib too
3191
3192         * girepository/gtypelib.c (_g_typelib_init):
3193         Use g_module_build_path to resolve the shlib name
3194
3195 2008-08-21  Colin Walters  <walters@verbum.org>
3196
3197         * gir/Makefile.am: CLEANFILES typelibs too.
3198
3199 2008-08-21  Johan Dahlin  <johan@gnome.org>
3200
3201         * giscanner/glibtransformer.py:
3202         Do not send .la files through find_library.
3203
3204 2008-08-21  Colin Walters  <walters@verbum.org>
3205
3206         * girepository/girparser.c (g_irepository_require):
3207         Fix one small leak in error case.
3208
3209 2008-08-21  Johan Dahlin  <johan@gnome.org>
3210
3211         * gir/Makefile.am:
3212         Parse glibconfig.h as well and install the compiled
3213         typelib
3214
3215 2008-08-21  Johan Dahlin  <johan@gnome.org>
3216
3217         * gir/Makefile.am:
3218         * giscanner/glibtransformer.py:
3219         * tools/g-ir-scanner:
3220         Do not hard-core library names in the Makefile, reuse
3221         ctypes find_library instead.
3222
3223 2008-08-21  Johan Dahlin  <johan@gnome.org>
3224
3225         * girepository/girparser.c (resolve_aliases):
3226         Remove compilation warnings
3227
3228 2008-08-21  Johan Dahlin  <johan@gnome.org>
3229
3230         * girepository/girepository.c (g_irepository_require):
3231         Rewrap and fix double free bug by leaking a bit.
3232
3233 2008-08-20  Colin Walters  <walters@verbum.org>
3234
3235         * girepository/girepository.c: Add new function
3236         g_irepository_get_typelib_path which tells
3237         us from where we loaded a namespace.
3238
3239 2008-08-20  Colin Walters  <walters@verbum.org>
3240
3241         * tests/scanner/*-expected.gir: Adjust for
3242         added shared-library.
3243         * giscanner/giwriter.py: Make pylint happy.
3244
3245 2008-08-20  Colin Walters  <walters@verbum.org>
3246
3247         * girepository/girmodule.c (g_ir_module_build_typelib):
3248         Calculate size correctly, avoid use-after-free.
3249
3250 2008-08-20  Colin Walters  <walters@verbum.org>
3251
3252         * girepository/girepository.c: Remove
3253         g_irepository_register_file in favor of
3254         g_irepository_require.  There are two
3255         possible deployment scenarios for typelibs:
3256         First, separate in $DATADIR/gitypelibs/.  Second,
3257         they may be embedded in shlibs.  However since
3258         the first is now the normal case, the API is
3259         optimized around it.
3260
3261         Refactor internals to look up typelibs for
3262         namespaces just-in-time, but we expect
3263         consumers to call g_irepository_require.
3264
3265         Also, add some docs.  No one has died from that
3266         before.
3267         * gir/Makefile.am: Need --library for glib.
3268         * giscanner/girwriter.py: Write out shared-library.
3269         * tools/g-ir-writer: Take the first --library
3270         argument as the target of shared-library.  In
3271         the future we should make this nicer with pkg-config
3272         probably.
3273
3274 2008-08-20  Colin Walters  <walters@verbum.org>
3275
3276         * girepository/girparser.py: And parse them.
3277
3278 2008-08-20  Johan Dahlin  <johan@gnome.org>
3279
3280         * giscanner/glibast.py: Add gshort/gushort types
3281
3282 2008-08-20  Colin Walters  <walters@verbum.org>
3283
3284         * gir/Makefile.am: Rename .gir files using GI namespace.
3285         * girepository/girepository.c: Use XDG_DATA_DIRS for
3286         looking up typelibs.  Also typelibs are now suffixed
3287         with .typelib.
3288         * tests/invoke/Makefile.am: Only use metadata.
3289         * girepository/Makefile.am: Remove unnecessary include.
3290         * tests/scanner/Makefile.am: Update using GI namespaces
3291         for scanner includes.
3292
3293 2008-08-20  Colin Walters  <walters@verbum.org>
3294
3295         * girepository/transformer.py: Suppress aliases whose
3296         name is a builtin.
3297         * girepository/ast.py: Define some more aliases.
3298
3299 2008-08-20  Colin Walters  <walters@verbum.org>
3300
3301         * girepository/girparser.c: Avoid alias infloops.
3302
3303 2008-08-20  Colin Walters  <walters@verbum.org>
3304
3305         * tests/scanner/foo-expected.gir: Fix expected list type.
3306
3307 2008-08-20  Johan Dahlin  <johan@gnome.org>
3308
3309         * giscanner/glibtransformer.py (GLibTransformer._resolve_type_name): 
3310         Add a workaround for #548689.
3311         We can now compile gtk!
3312
3313 2008-08-20  Colin Walters  <walters@verbum.org>
3314
3315         * giscanner/glibtransformer.py: Try to look up
3316         aliases using the c:type too.
3317
3318 2008-08-20  Colin Walters  <walters@verbum.org>
3319
3320         * girepository/girparser.c: Parse union fields.
3321
3322 2008-08-20  Johan Dahlin  <johan@gnome.org>
3323
3324         * giscanner/ast.py: Make time_t an alias for long
3325
3326         * gir/gio-2.0-good.gir:
3327         * gir/glib-2.0-good.gir:
3328         * gir/gobject-2.0-good.gir:
3329         Regnerate
3330         * giscanner/glibtransformer.py:
3331         Do not delete Class structures, we need them in gdk/gtk.
3332         * tests/scanner/drawable-expected.gir:
3333         * tests/scanner/foo-expected.gir:
3334         * tests/scanner/utility-expected.gir:
3335         Update tests.
3336
3337 2008-08-20  Johan Dahlin  <johan@gnome.org>
3338
3339         * tests/scanner/Makefile.am:
3340         * tests/scanner/annotation-expected.gir:
3341         * tests/scanner/annotation.c (annotation_object_class_init),
3342         (annotation_object_init), (annotation_object_method),
3343         (annotation_object_in), (annotation_object_out),
3344         (annotation_object_inout), (annotation_object_inout2),
3345         (annotation_object_inout3), (annotation_object_calleeowns),
3346         (annotation_object_calleesowns), (annotation_object_get_strings),
3347         (annotation_object_with_voidp), (annotation_object_get_objects),
3348         (annotation_object_create_object), (annotation_object_allow_none):
3349         * tests/scanner/annotation.h:
3350         * tests/scanner/foo-expected.gir:
3351         * tests/scanner/foo.c:
3352         * tests/scanner/foo.h:
3353         Split out annotation tests out of foo
3354
3355 2008-08-20  Johan Dahlin  <johan@gnome.org>
3356
3357         * tests/scanner/Foo-expected.gir:
3358         * tests/scanner/Makefile.am:
3359         * tests/scanner/foo-expected.gir:
3360         * tests/scanner/foo-object.h:
3361         * tests/scanner/foo.c:
3362         Foo->foo, foo-object.h -> foo.h
3363
3364 2008-08-20  Johan Dahlin  <johan@gnome.org>
3365
3366         * tests/scanner/Foo-expected.gir:
3367         * tests/scanner/Makefile.am:
3368         * tests/scanner/drawable-expected.gir:
3369         * tests/scanner/drawable.c (test_drawable_class_init),
3370         (test_drawable_init):
3371         * tests/scanner/drawable.h:
3372         * tests/scanner/foo-object.h:
3373         * tests/scanner/foo.c (foo_boxed_method):
3374         Move the drawable parts out of Foo to its own test.
3375
3376 2008-08-20  Johan Dahlin  <johan@gnome.org>
3377
3378         * tests/scanner/Foo-expected.gir:
3379         * tests/scanner/foo-object.h:
3380         * tests/scanner/foo.c (foo_drawable_class_init),
3381         (foo_drawable_init):
3382         Add a based on GdkDrawable which generates
3383         a broken gir.
3384
3385 2008-08-19  Colin Walters  <walters@verbum.org>
3386
3387         * giscanner/transformer.py: Don't try
3388         to strip prefix before namespace.
3389
3390 2008-08-19  Johan Dahlin  <johan@gnome.org>
3391
3392         * giscanner/transformer.py:
3393         * tests/scanner/Foo-expected.gir:
3394         * tests/scanner/foo-object.h:
3395         Add support for typedef void foo type of
3396         aliases.
3397
3398 2008-08-19  Johan Dahlin  <johan@gnome.org>
3399
3400         * giscanner/ast.py:
3401         * giscanner/girwriter.py:
3402         * giscanner/glibtransformer.py:
3403         * giscanner/transformer.py:
3404         * tests/scanner/Foo-expected.gir:
3405         Add basic support for union, base the code much
3406         on Struct. Add a testcase.
3407
3408 2008-08-19  Johan Dahlin  <johan@gnome.org>
3409
3410         * tests/scanner/Foo-expected.gir:
3411         * tests/scanner/foo-object.h:
3412         Add a union testcase which the compiler currently
3413         barfs at.
3414
3415 2008-08-19  Johan Dahlin  <johan@gnome.org>
3416
3417         * gobject-introspection-1.0.pc.in:
3418         Add a g_ir_compiler variable
3419
3420 2008-08-19  Colin Walters  <walters@verbum.org>
3421
3422         * giscanner/ast.py: Rework types to be more closely
3423         based on GITypeTag.
3424         * giscanner/girparser.py: Parse more bits.
3425         * giscanner/girwriter.py: Write sequences in a new
3426         way that specifies container type.
3427         * giscanner/glibast.py: Adjust for ast.py changes,
3428         add 'ctype' property to GLibObject and GLibInterface
3429         so we can look things up by it later.
3430         * gicanner/transformer.py: Names is new class holding
3431         the various namespaces we manage.  Do not confuse
3432         with Namespace which is toplevel XML node effectively.
3433         Rework all type resolution to go through
3434         _resolve_type_name_1.
3435         * giscanner/glibtransformer.py: Raise UnknownTypeError
3436         instead of ValueError for cleanliness.  Add Unresolved
3437         class to mark types whose parent we haven't seen yet.
3438         Use new Names object from transformer.py.
3439         Correctly look up parent=.
3440         Fix type validation to handle sequences.
3441         * tests/scanner/Foo-expected.gir: Update for sequence
3442         work, int instead of int32.
3443         * tools/g-ir-scanner: Add --noclosure option
3444         * gir/Makefile.am: Use --noclosure by default for
3445         GLib/GObject.
3446
3447 2008-08-18  Johan Dahlin  <johan@gnome.org>
3448
3449         * gir/gio-2.0-good.gir:
3450         * gir/glib-2.0-good.gir:
3451         * gir/gobject-2.0-good.gir:
3452         Regenerate.
3453
3454 2008-08-18  Johan Dahlin  <johan@gnome.org>
3455
3456         * giscanner/ast.py:
3457         * giscanner/girparser.py:
3458         * giscanner/girwriter.py:
3459         * giscanner/glibast.py:
3460         * giscanner/glibtransformer.py:
3461         * giscanner/transformer.py:
3462         * tests/scanner/Foo-expected.gir:
3463         * tests/scanner/foo-object.h:
3464         * tests/scanner/utility-expected.gir:
3465         * tests/scanner/utility.h:
3466         Redo type resolving and validation.
3467         Add a couple of new tests.
3468         Patch mostly written by Colin.
3469
3470 2008-08-18  Johan Dahlin  <johan@gnome.org>
3471
3472         * gir/Makefile.am:
3473         * giscanner/girparser.py:
3474         Set ctype of enums
3475         * giscanner/transformer.py:
3476         Improve enum parsing for enums without a GType.
3477         Make flags/enum references to other girs work
3478         * giscanner/utils.py:
3479         Simplify this a bit
3480         * tests/scanner/Makefile.am:
3481         * tests/scanner/foo-object.h:
3482         * tests/scanner/utility-expected.gir:
3483         * tests/scanner/utility.h:
3484         Add a new test for external enum references
3485
3486 2008-08-18  Johan Dahlin  <johan@gnome.org>
3487
3488         * docs/global-module-registry.txt: Update
3489
3490         * tests/array.gir: Update with new type proposal
3491
3492         * girepository/girepository.c (g_type_tag_to_string):
3493         * girepository/girepository.h:
3494         * girepository/girnode.c (g_ir_node_get_full_size_internal),
3495         (find_entry_node):
3496         * girepository/girnode.h:
3497         Make enum serializing functions public. Clean up some whitespace.
3498
3499 2008-08-17  Johan Dahlin  <johan@gnome.org>
3500
3501         * docs/global-module-registry.txt:
3502         Add a document for an on disk module registry format
3503
3504 2008-08-17  Johan Dahlin  <johan@gnome.org>
3505
3506         * gir/Makefile.am:
3507         * gir/gio-2.0-good.gir:
3508         Add a gio gir.
3509
3510 2008-08-17  Johan Dahlin  <johan@gnome.org>
3511
3512         * gir/Makefile.am:
3513         * gir/glib-2.0-good.gir:
3514         * gir/gobject-2.0-good.gir:
3515         * giscanner/cgobject.py:
3516         * giscanner/glibtransformer.py:
3517         Regenerate GObject & GType.
3518         Avoid warnings when generating gobject-2.0.gir.
3519         Introspect a little more, and skip *_get_type functions.
3520
3521 2008-08-17  Colin Walters  <walters@verbum.org>
3522
3523         * gir/glib-2.0.gir, gir/gobject-2.0.gir:
3524         Rename to -good, always generate during build.
3525         * gir/Makefile.am: Ensure .gir files dep on
3526         all scanner sources.
3527         * Makefile.am: Switch build order to ensure
3528         the scanner is ready before we do gir/.
3529         * tools/g-ir-scanner: Look for .git too.
3530
3531 2008-08-17  Johan Dahlin  <johan@gnome.org>
3532
3533         * girepository/gtypelib.c (validate_enum_blob):
3534         * giscanner/glibtransformer.py:
3535         * giscanner/transformer.py:
3536         Remove resolve_possible_typedefs, it was unused.
3537         Allow multiple enum values of the sample value in an enum,
3538         since it's actually pretty common.
3539         Register enums so they can be resolved too.
3540
3541 2008-08-16  Johan Dahlin  <johan@gnome.org>
3542
3543         * giscanner/girparser.py:
3544         Parse enumeration/bitfield.
3545
3546 2008-08-16  Johan Dahlin  <johan@gnome.org>
3547
3548         * giscanner/girparser.py:
3549         Parse boxed types.
3550
3551 2008-08-16  Johan Dahlin  <johan@gnome.org>
3552
3553         * giscanner/glibtransformer.py:
3554         Resolve type names for alias targets
3555         * giscanner/transformer.py:
3556         Skip FILE* parameters fow now
3557
3558 2008-08-16  Johan Dahlin  <johan@gnome.org>
3559
3560         * gir/glib-2.0.gir:
3561         * gir/gobject-2.0.gir:
3562         Regenerate
3563
3564         * tests/scanner/Makefile.am:
3565         parser -> scanner
3566
3567 2008-08-15  Colin Walters  <walters@verbum.org>
3568
3569         * giscanner/glibtransformer.py: Explicitly construct
3570         new list, since we're deleting as we iterate.
3571         Don't delete all structures which end in Class; just
3572         ones which have a paired GObject.
3573         Fix printing of type warning.
3574         * giscanner/transformer.py: Make strip_namespace_object
3575         be the identity function if it doesn't match the 
3576         namespace.
3577
3578 2008-08-15  Colin Walters  <walters@verbum.org>
3579
3580         * giscanner/cgobject.py: Define yet more argument
3581         prototypes; fix prototype for g_type_fundamental.
3582
3583 2008-08-14  Johan Dahlin  <johan@gnome.org>
3584
3585         * tests/Makefile.am:
3586         * tests/constant.gir:
3587         * tests/gobject.gir:
3588         * tests/struct.gir:
3589         * tools/generate.c (write_struct_info):
3590         Fix generator for constant/gobject/struct
3591
3592 2008-08-14  Johan Dahlin  <johan@gnome.org>
3593
3594         * tests/Makefile.am:
3595         * tests/enum.gir:
3596         * tools/generate.c (write_enum_info):
3597         Fix generation of enum/bitfields
3598
3599 2008-08-14  Johan Dahlin  <johan@gnome.org>
3600
3601         * girepository/girparser.c (start_field), (start_constant),
3602         (start_type), (end_element_handler):
3603         Clear up constant parsing
3604
3605         * tests/object.gir:
3606         Update
3607
3608         * tools/generate.c (write_callable_info), (write_function_info),
3609         (write_callback_info), (write_constant_info), (write_signal_info),
3610         (write_vfunc_info), (write_property_info), (write_object_info),
3611         (write_interface_info):
3612         Constants/Signals are handled now.
3613
3614 2008-08-14  Johan Dahlin  <johan@gnome.org>
3615
3616         * girepository/girparser.c (start_type):
3617         Don't require c:type.
3618         * tests/Makefile.am:
3619         Test boxed.gir
3620         * tests/boxed.gir:
3621         Update, remove parts we don't support yet
3622         * tests/roundtrips.sh:
3623         Remove
3624         * tools/generate.c (write_type_info), (write_field_info),
3625         (write_callable_info), (write_struct_info):
3626         Make it emit proper gir.
3627
3628 2008-08-14  Johan Dahlin  <johan@gnome.org>
3629
3630         * giscanner/transformer.py:
3631         New internal function for adding a new node.
3632
3633 2008-08-14  Johan Dahlin  <johan@gnome.org>
3634
3635         * gir/Makefile.am:
3636         Define an internal _H_ variable so we skip parsing both
3637         i18n headers, only one is needed.
3638         * gir/glib-2.0.gir:
3639         Add the glib-2.0.gir too.
3640         * giscanner/glibast.py:
3641         Add gconstpointer as an alias for ANY
3642         * giscanner/transformer.py:
3643         Do not lower case enumeration names per se.
3644         Skip functions which has parameters called 'va_list'
3645
3646 2008-08-14  Colin Walters  <walters@verbum.org>
3647
3648         * giscanner/transformer.py: Comment data structures.
3649         Also squash pointers in resolve_type_name to correspond
3650         with what we do for params.
3651         * giscanner/glibtransformer.py: Print warnings in more
3652         situations.  Rework checks for method/constructor to
3653         look up in our GType database instead of just checking
3654         for *.   Avoid generating <record> for GObject which
3655         duplicate the <class>.
3656         * gir/Makefile.am: Generate glib-2.0.gir and gobject-2.0.gir
3657         in here.
3658
3659 2008-08-14  Johan Dahlin  <johan@gnome.org>
3660
3661         * giscanner/girwriter.py:
3662         * giscanner/glibast.py:
3663         * giscanner/glibtransformer.py:
3664         * giscanner/transformer.py:
3665         * misc/pyflakes.py:
3666         * tests/Makefile.am:
3667         Add pyflakes.py and run it in make check.
3668         Update the source code to fix the errors reported by
3669         pyflakes.
3670
3671 2008-08-14  Johan Dahlin  <johan@gnome.org>
3672
3673         * giscanner/ast.py:
3674         * giscanner/girparser.py:
3675         * giscanner/glibast.py:
3676         * giscanner/glibtransformer.py:
3677         Refactor the parser a bit.
3678         Add parent type to interfaces and update callsites.
3679
3680 2008-08-14  Johan Dahlin  <johan@gnome.org>
3681
3682         * giscanner/glibtransformer.py:
3683         * giscanner/utils.py:
3684         Refactor a bit, avoid isinstance and add a method
3685         for each type we parse.
3686
3687 2008-08-14  Johan Dahlin  <johan@gnome.org>
3688
3689         * giscanner/ast.py:
3690         * giscanner/girparser.py:
3691         * giscanner/glibtransformer.py:
3692         * tests/Makefile.am:
3693         Run pep8.py in make check, fix old errors.
3694
3695 2008-08-13  Colin Walters  <walters@verbum.org>
3696
3697         * giscanner/girparser.py: Parse records.
3698
3699 2008-08-13  Colin Walters  <walters@verbum.org>
3700
3701         * gir/Makefile.am: Install again.
3702         * gir/gobject-2.0.gir: Add some more bits.
3703
3704 2008-08-13  Colin Walters  <walters@verbum.org>
3705
3706         * gir/gobject-2.0.gir: Use correct namespace, add GType.
3707         * giscanner/girparser.py: Handle aliases.
3708         * giscanner/transformer.py: Record aliases.  Make resolver
3709         functions public; we now call into these explicitly from
3710         glibtransformer.  Handle resolving aliases.
3711         * giscanner/glibtransformer.py: Separate our internal namespace
3712         from included ones.  Call up into transformer's resolver functions.
3713
3714 2008-08-13  Johan Dahlin  <johan@gnome.org>
3715
3716         * girepository/girnode.c (g_ir_node_get_full_size_internal):
3717         * girepository/girparser.c (start_class):
3718         * giscanner/glibtransformer.py:
3719         Allow get_type to be None, set a get_type for GInitiallyUnowned too.
3720
3721 2008-08-13  Johan Dahlin  <johan@gnome.org>
3722
3723         * giscanner/cgobject.py:
3724         Register GInitiallyUnowned
3725         * giscanner/girwriter.py:
3726         * giscanner/glibtransformer.py:
3727         Special case GObject/GInitially owned as they are a bit special to use.
3728
3729 2008-08-13  Colin Walters  <walters@verbum.org>
3730
3731         * tests/scanner/Foo-expected.gir, tests/scanner/utility-expected.gir:
3732         Object is in GObject namespace.
3733
3734 2008-08-13  Colin Walters  <walters@verbum.org>
3735
3736         * giscanner/girparser.py: Fix processing of functions
3737         from last commit.
3738
3739 2008-08-13  Colin Walters  <walters@verbum.org>
3740
3741         * giscanner/girparser.py: Parse more than just <class.
3742         * giscanner/glibtransformer.py: Put aliases in a separate
3743         data structure since their name is not canonicall.
3744         * giscanner/transformer.py: Handle resolving type names
3745         from includes.
3746
3747 2008-08-13  Johan Dahlin  <johan@gnome.org>
3748
3749         * tools/g-ir-scanner:
3750         Allow multiple libraries
3751         * giscanner/glibtransformer.py:
3752         Rename load_library to add_library, traverse over all libraries
3753         when trying to resolve a function
3754
3755 2008-08-12  Colin Walters  <walters@verbum.org>
3756
3757         * giscanner/transformer.py: Record typedefs as <alias> elements.
3758           Also attempt to look up types in external namespaces.
3759         * giscanner/girwriter.py: Write them.
3760         * giscanner/glibtransformer.py: Rework resolver using real instanceof
3761         checks.  Resolve interface methods and properties.
3762         * tests/scanner/foo-object.h: Add a method with typedef.
3763         * tests/scanner/Foo-expected.gir: Update.
3764         * girepository/girnode.c: Debug tweaks.
3765         * girepository/girparser.c: Make a first pass through the XML where we
3766         record all the aliases.  This lets us resolve them as we go through the
3767         second pass.
3768         * gir/Makefile.am: Don't install gobject-2.0.gir; we want that to come
3769         from gir-repository.
3770
3771 2008-08-12  Colin Walters  <walters@verbum.org>
3772
3773         * giscanner/glibtransformer.py: Resolve typedefs (e.g. AtkAttributeSet -> GSList).
3774         Correctly do subclasseing in 2nd pass resolution.  Handle callbacks in structure
3775         fields.
3776         * giscanner/transformer.py: Record typedefs and expose public API for resolving
3777         them.
3778         * tests/scanner/Foo-expected.gir: Fix expected callback types.
3779
3780 2008-08-12  Colin Walters  <walters@verbum.org>
3781
3782         * giscanner/glibtransformer.py: Also transform object properties.
3783
3784 2008-08-12  Colin Walters  <walters@verbum.org>
3785
3786         * giscanner/glibtransformer.py: Also transform callbacks
3787         and structure field types.
3788         * tests/scanner/Fooe-expected.gir: Update to expect correct
3789         names for callbacks and structs.
3790
3791 2008-08-12  Colin Walters  <walters@verbum.org>
3792
3793         * girepository/girparser.c: Handle 'any'.
3794         * tests/scanner/Foo-expected.gir, tests/scanner/foo-object.h:
3795         Add test for void *.
3796
3797 2008-08-12  Colin Walters  <walters@verbum.org>
3798
3799         * giscanner/glibtransformer.py: We need to do type
3800         resolution in a second pass after we've seen all the
3801         enums, records, etc.
3802
3803 2008-08-12  Colin Walters  <walters@verbum.org>
3804
3805         * tests/scanner/Foo-expected.gir, tests/scanner/foo-object.h:
3806         Add enum return value.
3807         * giscanner/glibtransformer.py: Transform function return types
3808         too.
3809
3810 2008-08-12  Colin Walters  <walters@verbum.org>
3811
3812         * tests/scanner/Makefile.am: Dep .gir files on scanner
3813         sources too.  Also remove @ so we see scanner invocations.
3814
3815 2008-08-12  Colin Walters  <walters@verbum.org>
3816
3817         * girepository/girparser.c, girepository/gtypelib.c,
3818         girepository/gtypelib.h, girepository/girnode.c:
3819         Remove usage of (GAPI-oriented) TypeTag in favor of
3820         GITypeTag from girepository.h.
3821
3822 2008-08-10  Colin Walters  <walters@verbum.org>
3823
3824         * tests/roundtrips.sh: Use the correct tests.
3825
3826 2008-08-10  Colin Walters  <walters@verbum.org>
3827
3828         * giscanner/cgobject.py: Declare/wrap a few more functions.
3829         Fix parameter types for g_object_new and g_type_fundamental.
3830
3831 2008-08-10  Colin Walters  <walters@verbum.org>
3832
3833         * giscanner/cgobject.py: Add new decorator @gwrap which forces
3834         us to declare types for both return value and parameters.  The
3835         ctypes default of 'int' is bad because it hides 32/64 bit
3836         problems.  Convert all existing functions to use it.
3837
3838 2008-08-09  Johan Dahlin  <johan@gnome.org>
3839
3840         * giscanner/__init__.py:
3841         * giscanner/ast.py:
3842         * giscanner/cgobject.py:
3843         * giscanner/gidlparser.py:
3844         * giscanner/gidlwriter.py:
3845         * giscanner/girparser.py:
3846         * giscanner/girwriter.py:
3847         * giscanner/glibast.py:
3848         * giscanner/glibtransformer.py:
3849         * giscanner/odict.py:
3850         * giscanner/sourcescanner.py:
3851         * giscanner/transformer.py:
3852         * giscanner/utils.py:
3853         * giscanner/xmlwriter.py:
3854         * tools/g-ir-scanner:
3855
3856         PEP8ify
3857
3858 2008-08-09  Johan Dahlin  <johan@gnome.org>
3859
3860         * relaxng/api.xml:
3861         * relaxng/c-types.xml:
3862         * relaxng/g-types.xml:
3863         * relaxng/relaxng.rng:
3864         * relaxng/util.xml:
3865         Remove outdated relaxng schemas.
3866
3867 2008-08-09  Johan Dahlin  <johan@gnome.org>
3868
3869         * *.[ch]:
3870         Rename metadata to typelib in variable names,
3871         comments and apis.
3872
3873 2008-08-09  Johan Dahlin  <johan@gnome.org>
3874
3875         * tools/scanner.c:
3876         * tools/scanner.h:
3877         Remove old C scanner, which got rewritten in python.
3878
3879 2008-08-09  Johan Dahlin  <johan@gnome.org>
3880
3881         * girepository/Makefile.am:
3882         * tools/Makefile.am:
3883         * tools/girmodule.c:
3884         * tools/girmodule.h:
3885         * tools/girnode.c:
3886         * tools/girnode.h:
3887         * tools/girparser.c:
3888         * tools/girparser.h:
3889         * tools/girwriter.c:
3890         * tools/girwriter.h:
3891         Move shared *.[ch] files to girepository from tools
3892
3893 2008-08-09  Johan Dahlin  <johan@gnome.org>
3894
3895         * tests/Makefile.am:
3896         * tests/array.test:
3897         * tests/boxed.test:
3898         * tests/constant.test:
3899         * tests/enum.test:
3900         * tests/errors.test:
3901         * tests/function.test:
3902         * tests/gobject.test:
3903         * tests/interface.test:
3904         * tests/object.test:
3905         * tests/struct.test:
3906         * tests/types.test:
3907         * tests/union.test:
3908         * tests/xref1.test:
3909         * tests/xref2.test:
3910         Rename *.test to *.gir
3911
3912 2008-08-09  Johan Dahlin  <johan@gnome.org>
3913
3914         * configure.ac:
3915         * tests/Makefile.am:
3916         * tests/parser/Foo-expected.gir:
3917         * tests/parser/Makefile.am:
3918         * tests/parser/foo-object.h:
3919         * tests/parser/foo.c:
3920         * tests/parser/utility-expected.gir:
3921         * tests/parser/utility.c:
3922         * tests/parser/utility.h:
3923         * tests/scanner/Makefile.am:
3924         Rename tests/parser to test/scanner
3925
3926 2008-08-08  Colin Walters  <walters@verbum.org>
3927
3928         * tests/roundtrips.sh: Use local .gir files again.
3929
3930 2008-08-08  Colin Walters  <walters@verbum.org>
3931
3932         * tests/invoke/Makefile.am: .gir file depends on libtool
3933         library.
3934
3935 2008-08-08  Colin Walters  <walters@verbum.org>
3936
3937         * tools/girnode.c: Pass through parent node so we can
3938         print the node whose child is NULL, if that occurs.
3939
3940 2008-08-08  Johan Dahlin  <johan@gnome.org>
3941
3942         * tests/Makefile.am:
3943         Disable roundtrip tests which are not yet working
3944         * tests/invoke/testfns.gir:
3945         Rewrite as gir.
3946
3947 2008-08-08  Johan Dahlin  <johan@gnome.org>
3948
3949         * giscanner/girwriter.py:
3950         type -> ntype
3951         * giscanner/glibast.py:
3952         * giscanner/glibtransformer.py:
3953         Swap order of members, to keep it consistent with
3954         base enum class
3955
3956 2008-08-08  Johan Dahlin  <johan@gnome.org>
3957
3958         * girepository/gtypelib.c (validate_header):
3959         * girepository/gtypelib.h:
3960         * giscanner/ast.py:
3961         * giscanner/girwriter.py:
3962         * giscanner/sourcescanner.c (gi_source_symbol_ref),
3963         (gi_source_symbol_unref):
3964         * tests/array.test:
3965         * tests/boxed.test:
3966         * tests/constant.test:
3967         * tests/enum.test:
3968         * tests/errors.test:
3969         * tests/function.test:
3970         * tests/gobject.test:
3971         * tests/interface.test:
3972         * tests/invoke/Makefile.am:
3973         * tests/invoke/testfns.xml:
3974         * tests/object.test:
3975         * tests/parser/Makefile.am:
3976         * tests/roundtrips.sh:
3977         * tests/struct.test:
3978         * tests/types.test:
3979         * tests/union.test:
3980         * tests/xref1.test:
3981         * tests/xref2.test:
3982         * tools/Makefile.am:
3983         * tools/compiler.c (main):
3984         * tools/generate.c (write_callable_info), (write_function_info),
3985         (write_repository):
3986         * tools/gidlmodule.c:
3987         * tools/gidlmodule.h:
3988         * tools/gidlnode.c:
3989         * tools/gidlnode.h:
3990         * tools/gidlparser.c:
3991         * tools/gidlparser.h:
3992         * tools/gidlwriter.c:
3993         * tools/gidlwriter.h:
3994         * tools/scanner.c (create_node_from_gtype),
3995         (create_node_from_ctype), (g_igenerator_process_properties),
3996         (g_igenerator_process_signals), (g_igenerator_create_object),
3997         (g_igenerator_create_interface), (g_igenerator_create_boxed),
3998         (g_igenerator_create_enum), (g_igenerator_create_flags),
3999         (g_igenerator_process_function_symbol),
4000         (g_igenerator_process_unregistered_struct_typedef),
4001         (g_igenerator_process_struct_typedef),
4002         (g_igenerator_process_union_typedef),
4003         (g_igenerator_process_enum_typedef),
4004         (g_igenerator_process_function_typedef),
4005         (g_igenerator_process_constant), (g_igenerator_process_symbols),
4006         (g_igenerator_add_module), (g_igenerator_add_include_idl):
4007         Merge in the gir-compiler branch.
4008         Thanks to Philip and Colin for their help.
4009
4010 2008-07-26  Colin Walters  <walters@verbum.org>
4011
4012         * tools/Makefile.am (bin_PROGRAMS): Install g-idl-compiler
4013         and g-idl-generate to go along with how we're changing this
4014         module to be installed.
4015         * gobject-introspection-1.0.pc.in: Set up Cflags and Libs.
4016
4017 2008-07-24  Colin Walters  <walters@verbum.org>
4018
4019         * girepository/girepository.c (g_irepository_register): Add
4020         environment variable G_IREPOSITORY_VERBOSE so we can print
4021         out what we're doing.
4022         * girepository/girepository.c (g_irepository_register_file): 
4023         Add GError error message to g_debug call.
4024
4025 2008-07-08  Jürg Billeter  <j@bitron.ch>
4026
4027         * giscanner/glibast.py:
4028
4029         Fix typo
4030
4031 2008-06-21  Johan Dahlin  <jdahlin@async.com.br>
4032
4033         * giscanner/girparser.py (GIRParser._parse_api): Ignore a few
4034         more tags
4035
4036 2008-06-20  Johan Dahlin  <jdahlin@async.com.br>
4037
4038         * giscanner/ast.py:
4039         * giscanner/girwriter.py:
4040         * giscanner/transformer.py:
4041         * tests/parser/Foo-expected.gir:
4042         * tests/parser/foo-object.h:
4043         * tests/parser/foo.c (foo_object_allow_none):
4044         Add support for gtk-doc annotations for allow-none.
4045         Add test case.
4046
4047 2008-06-19  Johan Dahlin  <jdahlin@async.com.br>
4048
4049         * giscanner/ast.py:
4050         * giscanner/girwriter.py:
4051         * giscanner/glibast.py:
4052         * giscanner/glibtransformer.py:
4053         * giscanner/transformer.py:
4054         * tests/parser/Foo-expected.gir:
4055         Start using abstract type instead of the raw C types.
4056         Register a bunch of glib types we care about.
4057
4058 2008-06-19  Rob Taylor  <rob.taylor@codethink.co.uk>
4059
4060         * AUTHORS:
4061         Update authors
4062
4063 2008-06-08  Philip Van Hoof  <pvanhoof@gnome.org>
4064
4065         * girepository/girepository.c:
4066         * girepository/gtypelib.c:
4067         * girepository/ginfo.c:
4068         * girepository/ginvoke.c:
4069         * girepository/girepository.h:
4070         * girepository/gtypelib.h:
4071         * girepository/gmetadata.c:
4072         * girepository/Makefile.am:
4073         * girepository/gmetadata.h:
4074         * tools/compiler.c:
4075         * tools/gidlmodule.c:
4076         * tools/gidlnode.c
4077         * tools/generate.c:
4078         * tools/gidlmodule.h:
4079         * tools/gidlparser.c:
4080
4081         Renamed GMetadata to GTypelib
4082
4083 2008-06-07  Johan Dahlin  <jdahlin@async.com.br>
4084
4085         * giscanner/xmlwriter.py:
4086         Improve line wrapping when > 79 charaters
4087
4088 2008-06-05  Jürg Billeter  <j@bitron.ch>
4089
4090         * giscanner/ast.py:
4091         * giscanner/girwriter.py:
4092         * giscanner/transformer.py:
4093         Use <type> element for field types
4094         * tests/parser/Foo-expected.gir:
4095         Update testcase
4096
4097 2008-06-04  Johan Dahlin  <jdahlin@async.com.br>
4098
4099         * giscanner/glibtransformer.py:
4100         Fix a bug which prevented GdkEvent from being generated
4101
4102 2008-06-03  Johan Dahlin  <jdahlin@async.com.br>
4103
4104         * giscanner/Makefile.am:
4105         * giscanner/ast.py:
4106         * giscanner/girwriter.py:
4107         * giscanner/glibast.py:
4108         * giscanner/glibtransformer.py:
4109         * giscanner/transformer.py:
4110         * giscanner/utils.py:
4111         * tests/parser/Foo-expected.gir:
4112         Improve enum member parsing and introspection
4113
4114 2008-05-31  Johan Dahlin  <jdahlin@async.com.br>
4115
4116         * giscanner/scannerparser.y:
4117         * giscanner/sourcescanner.h:
4118         * giscanner/sourcescanner.py:
4119         Add a new source type enum for member.
4120         Use __repr__ for improved debugging
4121         * giscanner/girparser.py:
4122         Ignore some more
4123         * giscanner/transformer.py:
4124         Improve parsing of struct members.
4125         * tests/parser/foo-object.h:
4126         Add a new testcase
4127
4128 2008-05-31  Johan Dahlin  <jdahlin@async.com.br>
4129
4130         * giscanner/xmlwriter.py:
4131         Improve error reporting when trying to quote None.
4132         * giscanner/girparser.py:
4133         Do not print warnings when including more complete .gir files
4134         * giscanner/girwriter.py:
4135         Do not require a name for parameters, add a todo for singletons
4136         * giscanner/glibtransformer.py:
4137         Refactor the way structs are done, add a couple of hacks to allow
4138         us to get further.
4139         * giscanner/transformer.py:
4140         Add enough hacks so cairo, atk and pango.gir can be parsed properly
4141         * gobject-introspection-1.0.pc.in:
4142         Export girdir, so we can access gobject-2.0.gir from outside
4143
4144 2008-05-31  Johan Dahlin  <jdahlin@async.com.br>
4145
4146         * tools/g-ir-scanner:
4147         * tests/parser/Makefile.am:
4148         Update sys.path before running the parser so we don't have
4149         to setup PYTHONPATH ourselves.
4150
4151         * Makefile.am:
4152         * configure.ac:
4153         * girepository/Makefile.am:
4154         * giscanner/transformer.py:
4155         * gobject-introspection-1.0.pc.in:
4156         * gobject-introspection.pc.in:
4157         * tools/Makefile.am:
4158
4159         Rename pkg-config name to gobject-introspection-1.0,
4160         Do not installed anything which is not using the gir format.
4161         Disable compililation the old C scanner, but still keep the source
4162         until all the remaning functionallity has been ported.
4163
4164 2008-05-31  Johan Dahlin  <jdahlin@async.com.br>
4165
4166         * giscanner/giscannermodule.c (symbol_get_ident): Prevent
4167         a crash when symbol->indent is NULL.
4168
4169         * giscanner/sourcescanner.py (ctype_name): Add ctype_name,
4170         a function to convert a CTYPE symbol to a string
4171
4172 2008-05-24  Johan Dahlin  <jdahlin@async.com.br>
4173
4174         * giscanner/ast.py:
4175         * giscanner/girwriter.py:
4176         * giscanner/giscannermodule.c
4177         (pygi_source_scanner_append_filename),
4178         (pygi_source_scanner_parse_file):
4179         * giscanner/glibtransformer.py:
4180         * giscanner/sourcescanner.py:
4181         Revert back to using temporary files to send in headers.
4182         Allow Functions to be passed in as callbacks, add a couple
4183         of try/excepts missing features.
4184         We can now scan pango
4185
4186 2008-05-08  Johan Dahlin  <johan@gnome.org>
4187
4188         * giscanner/glibtransformer.py:
4189         * giscanner/transformer.py:
4190         Move namespace stripping glibtransformer->transformer
4191
4192 2008-05-08  Johan Dahlin  <johan@gnome.org>
4193
4194         * giscanner/ast.py:
4195         * giscanner/girwriter.py:
4196         * giscanner/glibtransformer.py:
4197         * giscanner/transformer.py:
4198         * tools/g-ir-scanner:
4199         Introduce a namespace ast node
4200
4201 2008-05-05  Johan Dahlin  <johan@gnome.org>
4202
4203         * giscanner/__init__.py:
4204         * giscanner/sourcescanner.py:
4205         * giscanner/transformer.py:
4206         Move sourcescanner symbols to the sourcescanner module, instead
4207         of in the global __init__ namespace.
4208
4209 2008-05-03  Johan Dahlin  <johan@gnome.org>
4210
4211         * giscanner/glibtransformer.py:
4212         * tools/g-ir-scanner:
4213         Handle missing parameters better, allow - and + in .la dlname
4214         filenames.
4215
4216 2008-05-03  Johan Dahlin  <johan@gnome.org>
4217
4218         * giscanner/__init__.py:
4219         * giscanner/ast.py:
4220         * giscanner/girwriter.py:
4221         * giscanner/glibtransformer.py:
4222         * giscanner/transformer.py:
4223         Parse struct fields properly, improve debugging.
4224
4225 2008-04-29  Johan Dahlin  <johan@gnome.org>
4226
4227         * giscanner/ast.py:
4228         * giscanner/girwriter.py:
4229         * giscanner/transformer.py:
4230         * tests/parser/Foo-expected.gir:
4231         * TODO:
4232         Use transfer-ownership everywhere, to mark ownership/calle/caller etc.
4233
4234 2008-04-29  Johan Dahlin  <jdahlin@async.com.br>
4235
4236         * Makefile.am:
4237         * docs/g-ir-scanner.1:
4238         * metadata-annotations-proposal.txt:
4239         * metadata-format.txt:
4240         Add a basic, unfinshed man page for g-ir-scanner, move documents into .txt
4241
4242 2008-04-29  Johan Dahlin  <jdahlin@async.com.br>
4243
4244         * giscanner/girwriter.py:
4245         * giscanner/glibtransformer.py:
4246         * giscanner/transformer.py:
4247         * giscanner/xmlwriter.py:
4248         * tests/parser/Foo-expected.gir:
4249         * tests/parser/foo-object.h:
4250         Write record/structs to gir file too. Add a couple of tests,
4251         fix an off by one error in xmlwriter.py.
4252
4253 2008-04-28  Johan Dahlin  <johan@gnome.org>
4254
4255         * giscanner/xmlwriter.py: Calculate the line length properly,
4256         include the provided extra indentation in the calculation, really.
4257
4258 2008-04-28  Johan Dahlin  <jdahlin@async.com.br>
4259
4260         * giscanner/ast.py:
4261         * giscanner/glibast.py:
4262         * giscanner/glibtransformer.py:
4263         * giscanner/transformer.py:
4264         * tools/g-ir-scanner:
4265         Add a --strip-prefix and sort out confusion between names and symbols
4266         for functions and struct + derivaties.
4267         Refactor bootstrap of g-ir-scanner, so we can set options on
4268         Transformer() before parsing everything.
4269
4270 2008-04-28  Johan Dahlin  <johan@gnome.org>
4271
4272         * giscanner/transformer.py (Transformer._traverse_one): Avoid recursion
4273         when scanning girepository.h
4274
4275         * giscanner/sourcescanner.py (SourceScanner._preprocess): Define
4276         a __GI_SCANNER__ when we run.
4277
4278 2008-04-28  Johan Dahlin  <jdahlin@async.com.br>
4279
4280         * giscanner/ast.py:
4281         * giscanner/girwriter.py:
4282         * giscanner/glibast.py:
4283         * giscanner/glibtransformer.py:
4284         * tests/parser/Foo-expected.gir:
4285         * tests/parser/utility-expected.gir:
4286         Rename most c:identifier to c:type. Add new ones to
4287         class/interface/enum/boxed.
4288
4289 2008-04-28  Johan Dahlin  <jdahlin@async.com.br>
4290
4291         * giscanner/ast.py:
4292         * giscanner/girwriter.py:
4293         * giscanner/glibtransformer.py:
4294         * tests/parser/Foo-expected.gidl:
4295         * tests/parser/Makefile.am:
4296         Move c:identifier from return-value to subchild type,
4297         as per Jürgs suggestion
4298
4299 2008-04-28  Johan Dahlin  <johan@gnome.org>
4300
4301         * giscanner/girwriter.py:
4302         * tests/parser/Foo-expected.gir:
4303         Write property.type as a child node.
4304
4305 2008-04-27  Johan Dahlin  <johan@gnome.org>
4306
4307         * Makefile.am:
4308         * configure.ac:
4309         * gidl/Makefile.am:
4310         * gidl/gobject-2.0.gidl:
4311         * gir/Makefile.am:
4312         * gir/gobject-2.0.gir:
4313         * tests/parser/Makefile.am:
4314         Replace the GObject gidl with a GObject gir.
4315
4316 2008-04-27  Johan Dahlin  <johan@gnome.org>
4317
4318         * tools/Makefile.am (bin_SCRIPTS): g-ir-scanner is a script,
4319         not a program.
4320
4321         * giscanner/xmlwriter.py:
4322         * tests/parser/Foo-expected.gir:
4323         Include indentation in line length calculation
4324
4325 2008-04-27  Johan Dahlin  <johan@gnome.org>
4326
4327         * giscanner/girparser.py:
4328         Prettify NS parsing using elementtree.
4329
4330 2008-04-27  Johan Dahlin  <johan@gnome.org>
4331
4332         * configure.ac:
4333         * giscanner/Makefile.am:
4334         * giscanner/girparser.py:
4335         * giscanner/glibtransformer.py:
4336         * tests/parser/Foo-expected.gidl:
4337         * tests/parser/Foo-expected.gir:
4338         * tests/parser/Makefile.am:
4339         * tests/parser/utility-expected.gidl:
4340         * tests/parser/utility-expected.gir:
4341         * tools/g-ir-scanner:
4342         Switch over to GIR as the default format. Add a simple GIDL
4343         parser.
4344         Update tests and fix simplify makefiles by depending
4345         on GNU make extensions.
4346
4347 2008-04-27  Johan Dahlin  <johan@gnome.org>
4348
4349         * giscanner/xmlwriter.py:
4350         Wrap attributes for lines which are wider than 79 characters
4351
4352         * giscanner/scannerlexer.l:
4353         Allow parenthesis in annotations
4354
4355         * giscanner/ast.py:
4356         * giscanner/gidlwriter.py:
4357         * giscanner/girwriter.py:
4358         * giscanner/glibtransformer.py:
4359         * giscanner/transformer.py:
4360         Add initial sequence support, including annotation.
4361         Refactor type handling a bit.
4362
4363 2008-04-27  Johan Dahlin  <johan@gnome.org>
4364
4365         * tests/parser/Foo-expected.gidl:
4366         * tests/parser/foo-object.h:
4367         * tests/parser/foo.c (foo_object_class_init),
4368         (foo_object_get_strings), (foo_object_get_objects):
4369         Add two new functions to check sequence return values.
4370         Also fixes a compilation warning.
4371
4372 2008-04-27  Johan Dahlin  <johan@gnome.org>
4373
4374         * giscanner/giscannermodule.c (]): Cast the getter, avoids
4375         a compilation warning.
4376
4377         * tools/Makefile.am (g_ir_scanner_SOURCES):
4378         g-ir-scanner has no sources.
4379
4380 2008-04-25  Johan Dahlin  <johan@gnome.org>
4381
4382         * giscanner/Makefile.am:
4383         * giscanner/ast.py:
4384         * giscanner/gidlparser.py:
4385         * giscanner/gidlwriter.py:
4386         * giscanner/girwriter.py:
4387         * giscanner/glibast.py:
4388         * giscanner/glibtransformer.py:
4389         * giscanner/transformer.py:
4390         Split out nodes to ast.py and glibast.py
4391
4392 2008-04-25  Johan Dahlin  <jdahlin@async.com.br>
4393
4394         * giscanner/Makefile.am:
4395         * giscanner/gidlparser.py:
4396         * giscanner/gidlwriter.py:
4397         * giscanner/girwriter.py:
4398         * giscanner/glibtransformer.py:
4399         * giscanner/gobjecttreebuilder.py:
4400         * giscanner/transformer.py:
4401         * giscanner/treebuilder.py:
4402         * tools/g-ir-scanner:
4403         Rename treebuilder to transformer and
4404         gobjectreebuilder to glibtransformer.
4405
4406 2008-04-25  Johan Dahlin  <jdahlin@async.com.br>
4407
4408         * giscanner/Makefile.am:
4409         * giscanner/__init__.py:
4410         * giscanner/cgobject.py:
4411         * giscanner/gidlparser.py:
4412         * giscanner/gidlwriter.py:
4413         * giscanner/girwriter.py:
4414         * giscanner/gobjecttreebuilder.py:
4415         * giscanner/odict.py:
4416         * giscanner/sourcescanner.py:
4417         * giscanner/treebuilder.py:
4418         * giscanner/xmlwriter.py:
4419         * tools/Makefile.am:
4420         * tools/g-ir-scanner:
4421         Add LGPLv2 license header and install all python files
4422
4423 2008-04-25  Johan Dahlin  <jdahlin@async.com.br>
4424
4425         * TODO:
4426         * giscanner/gidlwriter.py:
4427         * giscanner/giscannermodule.c (pygi_source_directive_new),
4428         (directive_get_options), (pygi_source_symbol_new),
4429         (symbol_get_base_type), (pygi_source_type_new),
4430         (type_get_base_type), (type_get_child_list),
4431         (pygi_source_scanner_get_symbols),
4432         (pygi_source_scanner_get_directives):
4433         * giscanner/gobjecttreebuilder.py:
4434         * giscanner/sourcescanner.py:
4435         * giscanner/treebuilder.py:
4436         * tests/parser/foo-object.h:
4437         Add support for virtual methods.
4438         Pair struct FooClass with struct Foo.
4439         Clean up the SourceScanner bindings a bit.
4440         Add a testcase for virtual methods.
4441
4442 2008-04-25  Johan Dahlin  <jdahlin@async.com.br>
4443
4444         * giscanner/cgobject.py:
4445         * giscanner/gidlwriter.py:
4446         * giscanner/gobjecttreebuilder.py:
4447         Add support for signals
4448
4449         * tests/parser/foo.c (foo_object_class_init):
4450         * Foo-expected.gidl:
4451         Add a signal and update the expected output.
4452
4453 2008-04-24  Johan Dahlin  <jdahlin@async.com.br>
4454
4455         * giscanner/gidlwriter.py:
4456         * giscanner/girwriter.py:
4457         * giscanner/giscannermodule.c (directive_get_name),
4458         (directive_get_value), (directive_get_options),
4459         (symbol_get_directives), (symbol_set_directives),
4460         (pygi_source_scanner_parse_file),
4461         (pygi_source_scanner_lex_filename),
4462         (pygi_source_scanner_get_directives), (init_giscanner):
4463         * giscanner/sourcescanner.c (gi_source_scanner_get_directives):
4464         * giscanner/sourcescanner.h:
4465         * giscanner/sourcescanner.py:
4466         * giscanner/treebuilder.py:
4467         * tools/g-ir-scanner:
4468         Add support for source/header annotations.
4469
4470 2008-04-22  Johan Dahlin  <jdahlin@async.com.br>
4471
4472         * giscanner/gidlwriter.py:
4473         * giscanner/girwriter.py:
4474         * giscanner/gobjecttreebuilder.py:
4475         * giscanner/treebuilder.py:
4476         Add support for Callbacks
4477
4478 2008-04-22  Havoc Pennington  <hp@pobox.com>
4479
4480         * girepository/ginvoke.c (g_function_info_invoke): If a symbol is
4481         not in metadata->module, look for it in the global module, in case
4482         some other object or the app itself provides the symbol.
4483
4484 2008-04-22  Havoc Pennington  <hp@pobox.com>
4485
4486         * girepository/gmetadata.c (_g_metadata_init): hack to avoid
4487         dlopening a library that is already in the main app, by checking
4488         whether one of the lib's symbols is already loaded.
4489
4490 2008-04-22  Johan Dahlin  <jdahlin@async.com.br>
4491
4492         * tests/parser/Foo-expected.gidl:
4493         * tests/parser/foo-object.h:
4494         Add a callback test
4495
4496 2008-04-22  Havoc Pennington  <hp@pobox.com>
4497
4498         * girepository/ginfo.c (g_interface_info_find_method):
4499         Use interface_blob_size not object_blob_size to compute offset.
4500
4501 2008-04-22  Havoc Pennington  <hp@pobox.com>
4502
4503         * girepository/gmetadata.c (_g_metadata_init): remove
4504         G_MODULE_BIND_LOCAL flag when loading libraries, since some libs
4505         (Glade and Clutter for example) rely on being loaded globally.
4506
4507 2008-04-22  Havoc Pennington  <hp@pobox.com>
4508
4509         * girepository/ginfo.c (g_registered_type_info_get_g_type): new
4510         function to get the GType given a RegisteredTypeInfo
4511
4512 2008-04-22  Johan Dahlin  <johan@gnome.org>
4513
4514         * COPYING: Add a LGPL license, to prevent automake to
4515         put in a copy of GPL here. Pointed out by Havoc.
4516
4517         * girepository/ginfo.c (g_info_from_entry), (g_type_info_new),
4518         (g_type_info_is_pointer), (g_type_info_get_tag),
4519         (g_type_info_get_param_type), (g_type_info_get_interface),
4520         (g_type_info_get_array_length), (g_type_info_is_zero_terminated),
4521         (g_type_info_get_n_error_domains), (g_type_info_get_error_domain),
4522         (g_error_domain_info_get_codes), (g_enum_info_get_value),
4523         (g_object_info_get_interface), (g_object_info_get_field),
4524         (g_interface_info_get_prerequisite),
4525         (g_signal_info_get_class_closure), (g_constant_info_get_value):
4526         * girepository/ginvoke.c (get_ffi_type):
4527         * girepository/girepository.h:
4528         * girepository/gmetadata.c (g_metadata_get_dir_entry),
4529         (g_metadata_check_sanity), (validate_header),
4530         (validate_array_type_blob), (validate_iface_type_blob),
4531         (validate_param_type_blob), (validate_error_type_blob),
4532         (validate_type_blob), (validate_constant_blob),
4533         (validate_struct_blob), (validate_enum_blob):
4534         * girepository/gmetadata.h:
4535         * tests/Makefile.am:
4536         * tests/invoke/Makefile.am:
4537         * tests/invoke/invoke.c (main):
4538         * tests/roundtrips.sh:
4539         * tools/Makefile.am:
4540         * tools/compiler.c (format_output), (write_out_metadata), (main):
4541         * tools/generate.c (write_type_name), (write_type_info),
4542         (write_constant_value), (write_enum_info), (load_metadata), (main):
4543         * tools/gidlcompilercontext.c:
4544         * tools/gidlcompilercontext.h:
4545         * tools/gidlcompilerentrynode.c:
4546         * tools/gidlcompilerentrynode.h:
4547         * tools/gidlcompilertypenode.c:
4548         * tools/gidlcompilertypenode.h:
4549         * tools/gidlmodule.c (g_idl_module_build_metadata):
4550         * tools/gidlmodule.h:
4551         * tools/gidlnode.c (init_stats), (dump_stats),
4552         (g_idl_node_get_size), (g_idl_node_get_full_size),
4553         (g_idl_node_cmp), (g_idl_node_can_have_member),
4554         (g_idl_node_add_member), (g_idl_node_param_direction_string),
4555         (parse_int_value), (parse_uint_value), (parse_float_value),
4556         (parse_boolean_value), (find_entry_node), (find_entry),
4557         (serialize_type), (g_idl_node_build_metadata), (write_string):
4558         * tools/gidlnode.h:
4559         * tools/gidlparser.c (parse_type_internal):
4560         * tools/quote-file.sh:
4561         Revert revisions 157,149-148,136-129 and 120.
4562         Move back to using g-idl-generate to generate the metadata and
4563         avoids dependency on a c compiler.
4564
4565 2008-04-22  Johan Dahlin  <jdahlin@async.com.br>
4566
4567         * giscanner/girwriter.py:
4568         * tools/g-ir-scanner:
4569         Add an initial GIR writer and a --format option to g-ir-scanner
4570
4571 2008-04-21  Johan Dahlin  <johan@gnome.org>
4572
4573         * giscanner/cgobject.py: Use ctypes.util.find_library to locate
4574         gobject-2.0 and raise ImportError if not found.
4575
4576         * giscanner/gidlparser.py:
4577         * giscanner/gidlwriter.py:
4578         * giscanner/gobjecttreebuilder.py:
4579         * tools/g-ir-scanner:
4580         Add a --include argument to include types from other idls.
4581         Add a minimalistic GIDL parser (just objects for now)
4582         Implement resolving of external type references and use it to
4583         resolve parent types, argument types and return types.
4584
4585 2008-04-21  Johan Dahlin  <johan@gnome.org>
4586
4587         * giscanner/gidlwriter.py:
4588         * giscanner/gobjecttreebuilder.py:
4589         * giscanner/treebuilder.py:
4590         Add support for properties.
4591         Refactor Class/Interface support a bit, to share more code and
4592         always initialize their method attribute to an empty list.
4593
4594 2008-04-21  Johan Dahlin  <johan@gnome.org>
4595
4596         * giscanner/cgobject.py:
4597         Add a workaround for a glib bug interface introspection bug
4598         (object_interface_list_properties, object_class_list_properties):
4599         Cast the return value to GParamSpec.
4600
4601         * tests/parser/Foo-expected.gidl: Update
4602         * tests/parser/foo.c: Add a string property
4603
4604         * giscanner/gobjecttreebuilder.py:
4605         After stripping namespaces, remove the original
4606         item to avoid duplication (GtkButton struct and Button object)
4607
4608 2008-04-21  Johan Dahlin  <johan@gnome.org>
4609
4610         * giscanner/gobjecttreebuilder.py:
4611         * giscanner/treebuilder.py:
4612         Strip namespaces before objects, so we'll export
4613         GtkButton as Button in the gtk namespace
4614
4615 2008-04-21  Johan Dahlin  <johan@gnome.org>
4616
4617         * giscanner/gidlwriter.py:
4618         * giscanner/gobjecttreebuilder.py:
4619         * giscanner/treebuilder.py:
4620         Add constructors for object/boxed types.
4621
4622 2008-04-21  Johan Dahlin  <johan@gnome.org>
4623
4624         * giscanner/gidlwriter.py:
4625         * giscanner/gobjecttreebuilder.py:
4626         Add support for boxed types
4627
4628 2008-04-21  Johan Dahlin  <johan@gnome.org>
4629
4630         * giscanner/giscannermodule.c: Mark structures as const,
4631         wrap SourceType.const_string.
4632
4633         * tests/parser/foo-object.h: Add a couple of constants.
4634
4635         * giscanner/gidlwriter.py:
4636         * giscanner/gobjecttreebuilder.py:
4637         * giscanner/treebuilder.py:
4638         Add basic support for interfaces
4639
4640         * tools/g-ir-scanner:
4641         Add -o/--output for writing to a file
4642
4643 2008-04-21  Havoc Pennington  <hp@redhat.com>
4644
4645         * TODO: add some C API wishlist items I could think of quickly
4646
4647 2008-04-21  Johan Dahlin  <jdahlin@async.com.br>
4648
4649         * giscanner/gidlwriter.py:
4650         * giscanner/xmlwriter.py:
4651         Add a simple api for writing tags which can be used 
4652         with the new 'with statement' in python 2.5
4653
4654 2008-04-21  Johan Dahlin  <johan@gnome.org>
4655
4656         * giscanner/gobjecttreebuilder.py:
4657         Strip namespace and object prefix from method names.
4658
4659 2008-04-21  Johan Dahlin  <johan@gnome.org>
4660
4661         * tools/g-ir-scanner (main): Add --pkg option to pass in
4662         pkg-config modules to get cflags from.
4663
4664         * giscanner/gidlwriter.py (GIDLWriter._write_method): 
4665         Avoid duplication, reuse function writer for methods.
4666
4667 2008-04-21  Johan Dahlin  <jdahlin@async.com.br>
4668
4669         * giscanner/gidlwriter.py:
4670         * giscanner/gobjecttreebuilder.py:
4671         * giscanner/treebuilder.py:
4672         * tools/g-ir-scanner:
4673         Resolve libtool .la files.
4674         Strip name spaces for methods.
4675         Add function symbols
4676
4677 2008-04-20  Johan Dahlin  <jdahlin@async.com.br>
4678
4679         * giscanner/cgobject.py:
4680         * giscanner/gidlwriter.py:
4681         * giscanner/gobjecttreebuilder.py:
4682         * giscanner/treebuilder.py:
4683         Add support for classes and methods
4684
4685 2008-04-20  Johan Dahlin  <johan@gnome.org>
4686
4687         * giscanner/gidlwriter.py:
4688         * giscanner/gobjecttreebuilder.py:
4689         * giscanner/odict.py:
4690         Avoid conflicts, keep the output ordered similar to
4691         the order of the input.
4692         Add a simple ordered dictionary implemenation
4693
4694 2008-04-19  Johan Dahlin  <johan@gnome.org>
4695
4696         * giscanner/cgobject.py:
4697         * giscanner/gidlwriter.py:
4698         * giscanner/gobjecttreebuilder.py:
4699         * tools/g-ir-scanner:
4700         Start introspecting get-type functions.
4701         Implement support for GLib/GFlags GTypes.
4702         Add a ctype based GObject binding.
4703
4704 2008-04-18  Johan Dahlin  <jdahlin@async.com.br>
4705
4706         * giscanner/gidlwriter.py:
4707         * giscanner/xmlwriter.py:
4708         * tools/g-ir-scanner:
4709         Add a simplistic gidl writer, which can't do too much.
4710
4711 2008-04-18  Johan Dahlin  <johan@gnome.org>
4712
4713         * giscanner/sourcescanner.py:
4714         * giscanner/treebuilder.py:
4715         * tools/g-ir-scanner:
4716         split tree building and source scanning interface to separate files.
4717
4718 2008-04-18  Johan Dahlin  <johan@gnome.org>
4719
4720         * tools/g-ir-scanner (Parameter.__init__): Start constructing
4721         a real node tree.
4722         - Add support for struct/parameter/return, start parsing of ctypes
4723
4724         * giscanner/giscannermodule.c: wrap GISourceType.child_list and
4725         fix the style
4726
4727 2008-03-31  Johan Dahlin  <johan@gnome.org>
4728
4729         * tools/g-ir-scanner:
4730         Start to build abstract syntax node of scanned sources.
4731         Add support for cpp options.
4732
4733 2008-03-27  Johan Dahlin  <johan@gnome.org>
4734
4735         * giscanner/giscannermodule.c:
4736         * giscanner/scannerlexer.l:
4737         * giscanner/sourcescanner.c:
4738         * tools/g-ir-scanner:
4739
4740         Add simple pre-processor using subprocess and a PIPE.
4741         Change the parse_file apis to accept a file descriptor.
4742
4743 2008-03-25  Johan Dahlin  <johan@gnome.org>
4744
4745         * giscanner/__init__.py:
4746         * tools/g-ir-scanner:
4747         Fix a typo and add an example python test program.
4748
4749 2008-03-25  Johan Dahlin  <johan@gnome.org>
4750         
4751         * giscanner/__init__.py:
4752         * giscanner/giscannermodule.c:
4753         * giscanner/sourcescanner.c:
4754         * giscanner/sourcescanner.h:
4755         Add constants and wrap a few more SymbolType fields
4756
4757 2008-03-25  Johan Dahlin  <johan@gnome.org>
4758         
4759         * configure.ac:
4760         * giscanner:
4761         * giscanner/__init__.py:
4762         * giscanner/giscannermodule.c:
4763         * giscanner/Makefile.am:
4764
4765         Add initial python bindings for the scanner and 
4766         depend on python 2.5.
4767
4768 2008-03-25  Johan Dahlin  <johan@gnome.org>
4769
4770         * Makefile.am:
4771         * configure.ac:
4772         * giscanner/Makefile.am:
4773         * giscanner/sourcescanner.c:
4774         * giscanner/sourcescanner.h:
4775         * tools/Makefile.am:
4776         * tools/grealpath.h:
4777         * tools/sourcescanner.c:
4778         * tools/sourcescanner.h:
4779
4780         Move the scanner to a separate library.
4781         
4782 2008-03-23  Johan Dahlin  <johan@gnome.org>
4783
4784         * tools/Makefile.am:
4785         * tools/scanner.c:
4786         * tools/scanner.h:
4787         * tools/scannerlexer.l:
4788         * tools/scannerparser.y:
4789         * tools/sourcescanner.c:
4790         * tools/sourcescanner.h:
4791         Split out the source scanner from the generator.
4792         Rename the symbols used in the scanner to use the gi_ prefix.
4793         This should make it possible to use the raw C parser from
4794         other programs.
4795
4796 2008-03-23  Johan Dahlin  <johan@gnome.org>
4797
4798         * tests/parser/Makefile.am (utility.gidl): 
4799         * tests/parser/utility-expected.gidl: 
4800         Pass in the gobject.gidl since we're defining a GObject.
4801
4802 2008-03-12  Johan Dahlin  <johan@gnome.org>
4803
4804         * relaxng/relaxng.rng:
4805         Add a releaxng in relaxng we can use to validate the relaxngs
4806         schemas
4807
4808 2008-03-12  Jürg Billeter  <j@bitron.ch>
4809
4810         * tools/scanner.c: (g_igenerator_new):
4811         * tools/scannerparser.y:
4812         Fix compiler warnings.
4813
4814 2008-03-12  Jürg Billeter  <j@bitron.ch>
4815
4816         * tools/scanner.c:
4817         * tools/scanner.h:
4818         * tools/scannerparser.y:
4819         Start fixing memory management in g-idl-scanner.
4820
4821 2008-03-12  Rob Taylor  <rob.taylor@codethink.co.uk>
4822
4823         * tools/gidlcompilercontext.c: (write_compiled):
4824         Fix critical warning when no shlib passed to g-idl-compiler.
4825
4826 2008-03-12  Johan Dahlin  <johan@gnome.org>
4827
4828         * tests/parser/utility-expected.gidl:
4829         * tests/parser/utility.h:
4830         Add a get_type-function, so the scanner actually
4831         parses it as an object.
4832         
4833 2008-03-12  Johan Dahlin  <johan@gnome.org>
4834
4835         * tools/gidlwriter.c (function_generate): Add missing trailing quote.
4836         Bad Philip!
4837
4838         * tests/parser/Foo-expected.gidl:
4839         * tests/parser/Makefile.am:
4840         * tests/parser/foo-object.h:
4841         * tests/parser/foo.c:
4842         * tests/parser/utility-expected.gidl:
4843         * tests/parser/utility.c:
4844         * tests/parser/utility.h:
4845
4846         Add a new gidl test. 'utility.gidl', which is used to be able
4847         to test external type references. Add a reference to UtilityObject*
4848         in the idl file.
4849
4850 2008-03-11  Johan Dahlin  <johan@gnome.org>
4851
4852         * tools/compiler.c:
4853         * tools/generate.c:
4854         Remove most global variables
4855
4856 2008-03-11  Philip Van Hoof  <me@pvanhoof.be>
4857  
4858         * tools/scannerlexer.l:
4859         * tools/scanner.c:
4860         * tests/parser/Foo-expected.gidl:
4861         * tests/parser/foo.c:
4862         * tests/parser/Makefile.am:
4863         * tests/parser/foo-object.h:
4864  
4865         Added a few extra tests. Which resulted in finding a few
4866         bugs. Which resulted in me fixing those bugs
4867
4868 2008-03-11  Rob Taylor  <rob.taylor@codethink.co.uk>
4869
4870         * tools/gidlcompilercontext.c: (g_idl_compiler_write_dir_entry),
4871         (g_idl_compiler_write_xref_entry), (g_idl_compiler_add_xref):
4872         Add some comments for strings into generated output for
4873         easier debugging.
4874
4875 2008-03-11  Rob Taylor  <rob.taylor@codethink.co.uk>
4876
4877         * tools/gidlcompilercontext.c: (write_compiled):
4878         Write out the shlibs variable before writing out the strings
4879         length. Fixes compiler warning when using '-l' flag with
4880         g-idl-compiler
4881
4882 2008-03-11  Johan Dahlin  <johan@gnome.org>
4883
4884         * tests/parser/Foo-expected.gidl:
4885         * tests/parser/foo-object.h:
4886         * tools/scanner.c:
4887         * tools/scanner.h:
4888         * tools/scannerlexer.l:
4889         Add support for parsing return arguments. Add support for
4890         caller-owns return types.
4891         Patch by Philip Van Hoof.
4892         
4893         * tools/scannerparser.y:
4894         Remove parsing of the @deprecated syntax used in headers.
4895         We will support gtk-doc deprecation in the future instead.
4896
4897 2008-03-11  Johan Dahlin  <johan@gnome.org>
4898
4899         * tools/compiler.c (main): Coding style fixes
4900
4901 2008-03-10  Johan Dahlin  <johan@gnome.org>
4902
4903         * configure.ac:
4904         Add GCOV_LIBS to GILIBS
4905
4906 2008-03-10  Johan Dahlin  <johan@gnome.org>
4907
4908         * tests/parser/Foo-expected.gidl:
4909         * tests/parser/foo.c:
4910         Rename null-ok to direction=out
4911
4912 2008-03-10  Philip Van Hoof  <me@pvanhoof.be>
4913
4914         reviewed and extensively tested by Johan
4915
4916         * tests/parser/Foo-expected.gidl:
4917         * tests/parser/foo-object.h:
4918         * tests/parser/foo.c:
4919         * tools/gidlnode.c:
4920         * tools/gidlnode.h:
4921         * tools/gidlwriter.c:
4922         * tools/scanner.c:
4923         * tools/scanner.h:
4924         * tools/scannerlexer.l:
4925         * tools/scannerparser.y:
4926
4927         Add support for scanning for gtk-doc comments inside
4928         C source files. Add tests
4929
4930 2008-03-10  Johan Dahlin  <johan@gnome.org>
4931
4932         * tests/parser/Makefile.am:
4933         * tests/parser/foo.c:
4934         * tools/scanner.c:
4935         * tools/scanner.h:
4936         * tools/scannerparser.y:
4937         Add an api to lex filenames.
4938         Lex all source .c files passed in on the command line.
4939         Scan sources in a test and a couple of private structures
4940         which should not be included in the generated gidl
4941
4942 2008-03-10  Johan Dahlin  <johan@gnome.org>
4943
4944         * tests/invoke/Makefile.am: Make the generated metadata 
4945         depend on the g-idl-compiler
4946
4947 2008-02-21  Mark Doffman  <mark.doffman@codethink.co.uk>
4948
4949         * tools/gidlmodule.c
4950         * tools/gidlmodule.h
4951         * tools/gidlnode.c
4952         * tools/gidlnode.h
4953         Remove the old g-idl-compiler code.
4954
4955
4956 2008-02-22  Mark Doffman  <mark.doffman@codethink.co.uk>
4957
4958         * tools/quote-file.sh
4959         * tools/compiler.c
4960         * tools/generate.c
4961         Move to using the 'C' struct compiler code.
4962
4963 2008-02-21  Mark Doffman  <mark.doffman@codethink.co.uk>
4964
4965         * girepository/ginfo.c
4966         * tools/generate.c
4967         Change the way that external references with no namespace
4968         are dealt with. External references with no namespace
4969         are placed into the XML as-if they are a local reference.
4970         This is temporary, but helps with roundtrip tests.
4971
4972 2008-02-21  Mark Doffman  <mark.doffman@codethink.co.uk>
4973
4974         * girepository/ginfo.c
4975         Add the ability to get the value of a constant of
4976         type TYPE_TAG_SYMBOL. In the case of a symbol the value
4977         is provided as a string.
4978
4979         This would deal properly with:
4980         typedef char* random;
4981         const random = "A string";
4982
4983 2008-02-21  Mark Doffman  <mark.doffman@codethink.co.uk>
4984
4985         * girepository/ginfo.c
4986         * girepository/girepository.h
4987         * tools/generate.c
4988         Add a function to check if an enum is registered or not.
4989         Previously anything testing this relied on the g-type
4990         string offset having a value of 0.
4991
4992         * girepository/gmetadata.c
4993         * girepository/gmetadata.h
4994         * tools/generate.c
4995         Remove unneccesary or erroneous checks. There were two
4996         metadata validation checks which made sure that the blob
4997         sizes were the same as some magic numbers compiled into the code.
4998         This is wrong as it breaks any forwards compatibility that may
4999         be possible.
5000
5001         Checks were also present that made sure that unregistered type
5002         blobs had a value of 0 in the g-type offset field. This is
5003         unneccessary. If a type blob is unregistered then any value
5004         in its g-type field is simply invalid.
5005
5006 2008-02-21  Mark Doffman  <mark.doffman@codethink.co.uk>
5007
5008         * girepository/ginfo.c
5009         * girepository/gmetadata.c
5010         * girepository/gmetadata.h
5011
5012           Change the metadata format to have a standard header
5013           for all the type blobs. Merge the SimpleTypeBlob
5014           and InterfaceTypeBlob into a union. A union of these
5015           two blobs existed previously but was not explicit
5016           in the metadata format.
5017
5018 2008-02-21  Mark Doffman  <mark.doffman@codethink.co.uk>
5019
5020         * tools/gidlcompilercontext.c
5021         * tools/gidlcompilercontext.h
5022         * tools/gidlcompilerentrynode.c
5023         * tools/gidlcompilerentrynode.h
5024         * tools/gidlcompilertypenode.c
5025         * tools/gidlcompilertypenode.h
5026
5027         Add code to compile a tree of GIdlNodes to
5028         a 'C' struct representing the metadata.
5029         This is to aid cross-compiling. Previously
5030         the g-idl-compiler created a binary blob with
5031         data written in the byte order and alignment
5032         of the tool rather than the intended target.
5033
5034         Cleaned up and improved by Johan and Robert :-)
5035
5036 2008-02-21  Mark Doffman  <mark.doffman@codethink.co.uk>
5037
5038         * girepository/ginvoke.c
5039         * girepository/girepository.h
5040         * girepository/gmetadata.c
5041         * girepository/gmetadata.h
5042         * tools/generate.c
5043         * tools/gidlparser.c
5044         Modify TYPE_TAG_INTERFACE to TYPE_TAG_SYMBOL
5045         to avoid confusion with the interface blob.
5046
5047         * tools/generate.c
5048         * tools/gidlparser.c
5049         Remove magic numbers and replace with type-tag
5050         enumeration symbols.
5051
5052         * girepository/gmetadata.c
5053         Add validate declaration.
5054
5055 2008-03-10  Jürg Billeter  <j@bitron.ch>
5056
5057         * tools/gidlparser.c: (parse_type_internal):
5058         * tools/scannerlexer.l:
5059         * tools/scannerparser.y:
5060         Support C99 _Bool type in scanner.
5061
5062 2008-03-10  Jürg Billeter  <j@bitron.ch>
5063
5064         * tests/parser/Foo-expected.gidl:
5065         * tests/parser/foo-object.h:
5066         * tests/parser/foo.c: (foo_enum_method):
5067         * tools/scanner.c: (g_igenerator_process_function_symbol):
5068         Don't skip functions that are defined in the namespace of a type
5069         that doesn't support methods, as for example enums.
5070
5071 2008-03-10  Johan Dahlin  <johan@gnome.org>
5072
5073         * gidl.dtd: Remove, we're using relaxng for now
5074
5075         * tests/parser/Foo-expected.gidl:
5076         * tests/parser/foo-object.h:
5077         * tests/parser/foo.c:
5078         Rename the enum/flags get_type functions to include the whole type.
5079
5080 2008-03-08  Marc-Andre Lureau  <marcandre.lureau@gmail.com>
5081
5082         * tools/gidlwriter.c (enum_generate): added "type-name",
5083         "get-type" and "deprecated" missing arguments.
5084         * tests/parser/Foo-expected.gidl:
5085         * tests/parser/foo-object.h: test enum type, and no type.
5086
5087 2008-03-06  Johan Dahlin  <jdahlin@async.com.br>
5088
5089         * configure.ac:
5090         Consistent checks, add missing 'test'
5091
5092 2008-03-05  Havoc Pennington  <hp@redhat.com>
5093
5094         * configure.ac: Take advantage of a libffi.pc if one exists, as it
5095         does on Fedora 8. Make libffi a hard requirement, since it was in
5096         practice anyway (was not really conditional in the code or
5097         makefile, only in configure).
5098
5099 2008-02-21  Mark Doffman  <mark.doffman@codethink.co.uk>
5100
5101         reviewed by: Rob Taylor  <rob.taylor@codethink.co.uk>
5102         reviewed by: Johan Dahlin  <johan@gnome.org>
5103
5104         * tests/Makefile.am:
5105         * tests/roundtrips.sh:
5106         Modify the roundtrips test so that they do not use the
5107         --raw option of the gidl compiler but instead compile a
5108         shared library to use with g_module.
5109
5110         * tests/invoke/Makefile.am:
5111         * tests/invoke/invoke.c:
5112         Modify the invoke tests to build a shared library rather
5113         than use the --raw option.
5114
5115         * tests/invoke/invoke-namespace-find.sh: Removed:
5116         Noone knows why this was here, so removed.
5117
5118 2008-02-19  Rob Taylor  <rob.taylor@codethink.co.uk>
5119
5120         * tools/scanner.c: (g_igenerator_process_function_symbol):
5121         Move g_idl_node_can_have_member test later, as it broke spotting
5122         get_type's for nodes that can't have members.
5123
5124 2008-02-18  Rob Taylor  <rob.taylor@codethink.co.uk>
5125
5126         * tools/gidlnode.h:
5127         * tools/gidlnode.c: (g_idl_node_can_have_member):
5128         Add g_idl_node_can_have_member.
5129
5130         * tools/scanner.c: (g_igenerator_process_function_symbol):
5131         Use g_idl_node_can_have_member to test if we should add a function
5132         as a member of the type node.
5133
5134 2008-02-18  Rob Taylor  <rob.taylor@codethink.co.uk>
5135
5136         * gidl/GLib.gidl: Renamed to gidl/gobject-2.0.gidl:
5137         * gidl/Makefile.am:
5138         * tests/parser/Makefile.am:
5139         Rename GLib.gidl to gobject-2.0.gidl and install in /usr/share/gidl.
5140
5141 2008-02-18  Rob Taylor  <rob.taylor@codethink.co.uk>
5142
5143         * tools/scanner.c: (main):
5144         Ignore -pthread when passed to g-idl-scanner.
5145
5146 2008-02-18  Rob Taylor  <rob.taylor@codethink.co.uk>
5147
5148         * tools/grealpath.h: Added:
5149         * tools/scanner.c: (main):
5150         * tools/scannerlexer.l:
5151         * tools/Makefile.am:
5152         Always use absolute paths with symbolic links resolved when
5153         comparing filenames.
5154
5155 2008-02-18  Rob Taylor  <rob.taylor@codethink.co.uk>
5156
5157         * gobject-introspection.pc.in:
5158         Provide variables for g-idl-parser, scanner and compiler in the
5159         pkgconfig file.
5160
5161 2008-02-13  Rob Taylor  <rob.taylor@codethink.co.uk>
5162
5163         * gcov.mak:
5164         * girepository/Makefile.am:
5165         * tools/Makefile.am:
5166         Rename GCOV_SOURCES to GCOVSOURCES to top automake complaining.
5167
5168 2008-02-10  Johan Dahlin  <johan@gnome.org>
5169
5170         * tests/parser/Foo-expected.gidl:
5171         * tests/parser/foo-object.h:
5172         * tests/parser/foo.c: (foo_boxed_copy), (foo_boxed_free),
5173         (foo_boxed_get_type), (foo_boxed_new), (foo_boxed_method):
5174         Add boxed test.
5175
5176 2008-02-10  Johan Dahlin  <johan@gnome.org>
5177
5178         * tests/parser/Foo-expected.gidl:
5179         * tests/parser/foo-object.h:
5180         * tests/parser/foo.c: (foo_enum_get_type), (foo_flags_get_type):
5181         Add enum and flags test.
5182
5183 2008-02-10  Johan Dahlin  <johan@gnome.org>
5184
5185         * Makefile.am:
5186         * configure.ac:
5187         * girepository/Makefile.am:
5188         Make 'make distcheck' work again.
5189
5190 2008-02-10  Johan Dahlin  <johan@gnome.org>
5191
5192         * m4/Makefile.am (EXTRA_DIST): its called as-compiler-flag.m4,
5193         not as-compiler.m4.
5194
5195         * tests/parser/Makefile.am: Only create Foo.gidl when running make
5196         check, eg exclude it from BUILT_SOURCES.
5197
5198 2008-02-08  Rob Taylor  <rob.taylor@codethink.co.uk>
5199
5200         * Makefile.am:
5201         * configure.ac:
5202         * gcov.mak: Added:
5203         * girepository/Makefile.am:
5204         * m4/Makefile.am: Added:
5205         * m4/as-compiler-flag.m4: Added:
5206         * m4/gcov.m4: Added:
5207         * tools/Makefile.am:
5208         Add ability to generate a coverage report.
5209         Adds configure option --enable-gcov and make rule 'check-coverage'.
5210
5211 2008-02-08  Rob Taylor  <rob.taylor@codethink.co.uk>
5212
5213         * Makefile.am:
5214         * configure.ac:
5215         * gidl/Makefile.am: Added:
5216         * girepository/Makefile.am: Added:
5217         * src/Makefile.am: Renamed to tools/Makefile.am:
5218         * src/compiler.c: Renamed to tools/compiler.c:
5219         * src/g-idl-offsets.pl: Renamed to tools/g-idl-offsets.pl:
5220         * src/generate.c: Renamed to tools/generate.c:
5221         * src/gidlmodule.c: Renamed to tools/gidlmodule.c:
5222         * src/gidlmodule.h: Renamed to tools/gidlmodule.h:
5223         * src/gidlnode.c: Renamed to tools/gidlnode.c:
5224         * src/gidlnode.h: Renamed to tools/gidlnode.h:
5225         * src/gidlparser.c: Renamed to tools/gidlparser.c:
5226         * src/gidlparser.h: Renamed to tools/gidlparser.h:
5227         * src/gidlwriter.c: Renamed to tools/gidlwriter.c:
5228         * src/gidlwriter.h: Renamed to tools/gidlwriter.h:
5229         * src/ginfo.c: Renamed to girepository/ginfo.c:
5230         * src/ginvoke.c: Renamed to girepository/ginvoke.c:
5231         * src/girepository.c: Renamed to girepository/girepository.c:
5232         * src/girepository.h: Renamed to girepository/girepository.h:
5233         * src/gmetadata.c: Renamed to girepository/gmetadata.c:
5234         * src/gmetadata.h: Renamed to girepository/gmetadata.h:
5235         * src/scanner.c: Renamed to tools/scanner.c:
5236         * src/scanner.h: Renamed to tools/scanner.h:
5237         * src/scannerlexer.l: Renamed to tools/scannerlexer.l:
5238         * src/scannerparser.y: Renamed to tools/scannerparser.y:
5239         * tests/invoke/Makefile.am:
5240         Split src/ into girepository/ and tools/
5241
5242         * Makefile.am:
5243         * configure.ac:
5244         * girepository/Makefile.am:
5245         * tests/Makefile.am:
5246         * tests/invoke/Makefile.am:
5247         * tests/parser/Makefile.am:
5248         * tests/roundtrips.sh:
5249         * tools/Makefile.am:
5250         Make distcheck work.
5251
5252 2008-02-04  Rob Taylor  <rob.taylor@codethink.co.uk>
5253
5254         * tests/invoke/invoke.c: (main):
5255         * tests/invoke/testfns.c: (test6), (test7):
5256         * tests/invoke/testfns.xml:
5257         Add tests for invokation with a GList argument.
5258         Also tests caller-owns return values.
5259
5260 2008-02-04  Rob Taylor  <robtaylor@floopily.org>
5261
5262         * src/ginfo.c:
5263         Add some documentation for GICallableInfo
5264
5265 2008-02-01  Mark Doffman  <mark.doffman@codethink.co.uk>
5266
5267         * gidl.dtd:
5268         Correct syntax errors in the DTD file.
5269         * relaxng/api.xml:
5270         * relaxng/c-types.xml:
5271         * relaxng/g-types.xml:
5272         * relaxng/util.xml:
5273         Add a RelaxNG specification for the GObject Introspection XML data.
5274         The Specification has validated all of the test files.
5275
5276 2008-01-25  Rob Taylor  <robtaylor@floopily.org>
5277
5278         * tests/roundtrips.sh:
5279         * tests/struct.test:
5280         Add roundtrip tests for structs.
5281
5282 2008-01-11  Johan Dahlin  <johan@gnome.org>
5283
5284         * src/scanner.c (g_igenerator_process_function_symbol):
5285         Refactor out g_idle_node_add_member.
5286         (create_node_from_gtype, create_node_from_ctype):
5287         Use case instead of if...else
5288         (get_type_from_type_id):
5289         Rename to create_node_from_gtype
5290         (get_type_from_ctype):
5291         Rename to create_node_from_ctype
5292
5293         Rename ginode -> node, gitype -> type, gifunc -> func.
5294
5295         * src/gidlnode.c (g_idl_node_add_member, g_idl_node_cmp):
5296         Two new functions, refactor out of scanner.c
5297
5298         * src/scanner.c: (g_igenerator_process_function_symbol):
5299         * src/scannerlexer.l:
5300         Do not save the content of the deprecated variable, only
5301         if it's set or not.
5302
5303 2008-01-11  Johan Dahlin  <johan@gnome.org>
5304
5305         * tests/parser/foo-object.h: Add a couple of comment parser tests.
5306
5307 2008-01-11  Jürg Billeter  <j@bitron.ch>
5308
5309         * src/scannerlexer.l:
5310         Fix GTK-Doc parsing.
5311
5312 2008-01-11  Jürg Billeter  <j@bitron.ch>
5313
5314         * src/scannerlexer.l:
5315         Fix GTK-Doc parsing.
5316
5317 2008-01-11  Jürg Billeter  <j@bitron.ch>
5318
5319         * src/scanner.c: (lookup_symbol):
5320         Return unresolved name if we find unknown symbol.
5321
5322 2008-01-11  Jürg Billeter  <j@bitron.ch>
5323
5324         * src/scanner.c: (g_igenerator_generate):
5325         Initialize GObject to fix scanning interface properties.
5326
5327         * tests/parser/Foo-expected.gidl:
5328         * tests/parser/foo-object.h:
5329         * tests/parser/foo.c: (foo_interface_get_type):
5330         Test interfaces with GObject prerequisite.
5331
5332         * tests/parser/Makefile.am:
5333         Set G_DEBUG=fatal_warnings to abort test on warnings and criticals.
5334
5335 2007-12-27  Johan Dahlin  <johan@gnome.org>
5336
5337         * src/scannerlexer.l:
5338         Parse gtk-doc comments.
5339
5340         * src/gidlwriter.c: (function_generate):
5341         Reorganize, avoid duplication and add support for
5342         writing deprecated functions.
5343
5344         * src/scannerparser.y:
5345         * src/scanner.h:
5346         Add new structure CDirective and functions to create/free them.
5347
5348         * src/scanner.c: (g_igenerator_process_function_symbol),
5349         (g_igenerator_process_unregistered_struct_typedef),
5350         (g_igenerator_process_struct_typedef),
5351         (g_igenerator_process_union_typedef),
5352         (g_igenerator_process_enum_typedef),
5353         (g_igenerator_process_function_typedef), (g_igenerator_add_symbol),
5354         (g_igenerator_start_preprocessor):
5355         Parse @deprecated directive for functions.
5356         Remove some more C99isms.
5357         Send in -C to cpp to avoid stripping comments.
5358
5359         * tests/parser/foo-object.h:
5360         * tests/parser/Foo-expected.gidl:
5361         Add deprecated directive
5362
5363 2007-12-27  Johan Dahlin  <johan@gnome.org>
5364
5365         * src/scannerlexer.l (intsuffix): Add emacs mode line and
5366         escape ' and " so it looks more like C.
5367
5368         * src/scanner.c:
5369         Unlink temporary file used.
5370
5371 2007-12-27  Johan Dahlin  <johan@gnome.org>
5372
5373         * src/scanner.c: (g_igenerator_new), (g_igenerator_free),
5374         (g_igenerator_start_preprocessor), (main):
5375         * src/scanner.h:
5376         * src/scannerparser.y:
5377         Plug a couple of simple memory leaks.
5378
5379 2007-12-27  Johan Dahlin  <johan@gnome.org>
5380
5381         * src/scanner.c: (g_igenerator_parse_macros),
5382         (g_igenerator_start_preprocessor), (g_igenerator_set_verbose),
5383         (main):
5384         * src/scanner.h:
5385         * src/scannerparser.y:
5386         * tests/parser/Makefile.am:
5387
5388         Improve error reporting, return when the preprocessor fails.
5389         Add a verbose parameter, to aid debugging.
5390         Revert to using a temporary file to communicate between the
5391         preprocessor and the parser, because we need to wait for
5392         the exit code from the pre-processor before starting to parse.
5393
5394 2007-12-16  Johan Dahlin  <jdahlin@async.com.br>
5395
5396         * src/Makefile.am: Rename clexer.l to scannerlexer.l and
5397         cparser.y to scannerparser.y
5398
5399 2007-12-11  Johan Dahlin  <johan@gnome.org>
5400
5401         * src/clexer.l:
5402         * src/cparser.y:
5403         * src/scanner.c: (g_igenerator_new):
5404         * src/scanner.h:
5405         Get rid of the global the_generator variable.
5406
5407 2007-12-10  Johan Dahlin  <johan@gnome.org>
5408
5409         * src/scanner.c (main): Add an output option,
5410         add checks for required parameters
5411
5412         * src/Makefile.am:
5413         set BUILD_SOURCES and CLEANFILES properly
5414
5415         * src/gidlwriter.c: (g_writer_write_inline), (g_writer_write),
5416         (g_writer_write_indent), (g_writer_write_unindent),
5417         (field_generate), (value_generate), (constant_generate),
5418         (property_generate), (function_generate), (vfunc_generate),
5419         (signal_generate), (interface_generate), (struct_generate),
5420         (union_generate), (boxed_generate), (enum_generate),
5421         (node_generate), (g_writer_write_module), (g_idl_writer_save_file):
5422         * src/gidlwriter.h:
5423         * src/scanner.c: (g_igenerator_generate):
5424         * src/scanner.h:
5425         * src/scannerwriter.c:
5426
5427         Refactor scannerwriter to only be tied to a GIdlModule and move
5428         it (again!) to gidlwriter.c. Change the writer function to take
5429         a filename.
5430
5431 2007-12-10  Johan Dahlin  <johan@gnome.org>
5432
5433         * src/Makefile.am:
5434         * src/scanner.c: (g_igenerator_generate):
5435         * src/scanner.h:
5436         * src/scannerwriter.c: (g_igenerator_write_inline),
5437         (g_igenerator_write), (g_igenerator_write_indent),
5438         (g_igenerator_write_unindent), (field_generate), (value_generate),
5439         (constant_generate), (property_generate), (function_generate),
5440         (vfunc_generate), (signal_generate), (interface_generate),
5441         (struct_generate), (union_generate), (boxed_generate),
5442         (enum_generate), (node_generate), (module_generate),
5443         (g_scanner_write_file):
5444
5445         Move the scanner gidl writing to a separate source file.
5446
5447 2007-12-10  Johan Dahlin  <johan@gnome.org>
5448
5449         * src/cparser.y:
5450         * src/scanner.c:
5451         * src/scanner.h:
5452         Move over all CType construction functions.
5453
5454         * tests/parser/Makefile.am:
5455         Be verbose when printing parsing tests results.
5456
5457 2007-12-10  Johan Dahlin  <johan@gnome.org>
5458
5459         * src/scanner.c (g_igenerator_start_preprocessor): Refactor
5460         preprocessor handling to here. Start cpp insteado of cc -E,
5461         always include -U__GNUC__, since it's specific to the preprocessor
5462         we use.
5463
5464         * tests/parser/Makefile.am (check-local): Silent diff and skip
5465         -U__GNUC__ which is always defined now
5466
5467 2007-12-10  Johan Dahlin,,,  <jdahlin@plasttroll>
5468
5469         reviewed by: <delete if not using a buddy>
5470
5471         * src/scanner.c: (g_igenerator_start_preprocessor), (main):
5472         * tests/parser/Makefile.am:
5473
5474 2007-12-09  Johan Dahlin  <johan@gnome.org>
5475
5476         * src/scanner.c:
5477         Use GOption for command line options.
5478         (g_igenerator_new, main): Simplify constructor and they way
5479         parameters are passed into it.
5480
5481         * src/cparser.y:
5482         * src/Makefile.am:
5483         * src/clexer.l:
5484         * src/cparser.y:
5485         * src/gen-introspect.c:
5486         * src/gen-introspect.h:
5487         * src/scanner.c:
5488         Rename gen-introspect.[ch] to scanner.[ch]
5489
5490 2007-12-09  Johan Dahlin  <johan@gnome.org>
5491
5492         * TODO: Update
5493
5494         * src/Makefile.am: Rename gen-introspect to g-idl-scanner,
5495         don't make the repository library and the other utilites link against
5496         gthread-2.0
5497
5498         * src/gen-introspect.c: (g_igenerator_create_object),
5499         (g_igenerator_create_interface), (g_igenerator_create_boxed),
5500         (g_igenerator_create_enum), (g_igenerator_create_flags),
5501         (g_igenerator_process_module_symbol),
5502         (g_igenerator_process_module), (g_igenerator_generate), (main):
5503         * src/gen-introspect.h:
5504         Refactor g_igenerator_process_types into smaller pieces.
5505
5506         * tests/parser/Makefile.am:
5507         Depend on the gen-introspect binary
5508
5509 2007-12-09  Johan Dahlin  <johan@gnome.org>
5510
5511         * src/gen-introspect.c (g_igenerator_process_types):
5512         Break into smaller pieces, one for each generated node type.
5513
5514 2007-12-08  Johan Dahlin  <johan@gnome.org>
5515
5516         * src/gen-introspect.c: (g_igenerator_process_types),
5517         (g_igenerator_add_module):
5518         * tests/parser/Foo-expected.gidl:
5519         * tests/parser/foo-object.h:
5520         * tests/parser/foo.c: (foo_subobject_class_init),
5521         (foo_subobject_init):
5522
5523         Add a subobject test and make sure to register defined classes
5524         in the lookup symbol hash table.
5525
5526 2007-12-08  Johan Dahlin  <johan@gnome.org>
5527
5528         * gidl/GLib.gidl:
5529         * src/Makefile.am:
5530         * src/gen-introspect.c: (g_igenerator_new), (lookup_symbol),
5531         (g_igenerator_process_types), (g_igenerator_add_module),
5532         (g_igenerator_add_include_idl), (main):
5533         * src/gen-introspect.h:
5534         * tests/parser/Makefile.am:
5535         * tests/parser/Foo-expected.gidl:
5536
5537         Change the gen-introspect to generate namespaced module names,
5538         such as GLib.Object instead of GObject.
5539         Add a GLib.gidl which introduces GLib.Object and GLib.InitiallyUnowned,
5540         add a --include-idl parameter to gen-introspect,
5541         and update the parser test.
5542
5543 2007-12-08  Johan Dahlin  <johan@gnome.org>
5544
5545         * src/gen-introspect.c:
5546         Move main to the end of the file and attempt to make it valid
5547         ansi c.
5548
5549         * tests/parser/Makefile.am (BUILT_SOURCES): Remove .repo here,
5550         we're not quite ready to generate metadata yet.
5551
5552         * tests/parser/:
5553         * configure.ac:
5554
5555         Add a simple gen-introspect parser test
5556
5557 2007-12-06  Gustavo J. A. M. Carneiro  <gjc@gnome.org>
5558
5559         reviewed by: Johan Dahlin  <johan@gnome.org>
5560
5561         * configure.ac:
5562         * gobject-introspection.pc.in:
5563         * src/Makefile.am:
5564         * src/compiler.c: (format_output), (write_out_metadata), (main):
5565         * src/gen-introspect.c: (main):
5566         * src/gen-introspect.h:
5567         * src/generate.c: (write_callable_info), (write_repository),
5568         (load_metadata), (main):
5569         * src/gidlmodule.c: (g_idl_module_new),
5570         (g_idl_module_build_metadata):
5571         * src/gidlmodule.h:
5572         * src/gidlparser.c: (start_element_handler):
5573         * src/ginfo.c: (g_info_new), (g_info_from_entry),
5574         (g_base_info_get_name), (g_base_info_get_namespace),
5575         (g_base_info_is_deprecated), (g_base_info_get_annotation),
5576         (g_base_info_get_metadata), (g_function_info_get_symbol),
5577         (g_function_info_get_flags), (g_function_info_get_property),
5578         (g_function_info_get_vfunc), (signature_offset), (g_type_info_new),
5579         (g_callable_info_may_return_null),
5580         (g_callable_info_get_caller_owns), (g_callable_info_get_n_args),
5581         (g_callable_info_get_arg), (g_arg_info_get_direction),
5582         (g_arg_info_is_return_value), (g_arg_info_is_dipper),
5583         (g_arg_info_is_optional), (g_arg_info_may_be_null),
5584         (g_arg_info_get_ownership_transfer), (g_type_info_is_pointer),
5585         (g_type_info_get_tag), (g_type_info_get_param_type),
5586         (g_type_info_get_interface), (g_type_info_get_array_length),
5587         (g_type_info_is_zero_terminated),
5588         (g_type_info_get_n_error_domains), (g_type_info_get_error_domain),
5589         (g_error_domain_info_get_quark), (g_error_domain_info_get_codes),
5590         (g_value_info_get_value), (g_field_info_get_flags),
5591         (g_field_info_get_size), (g_field_info_get_offset),
5592         (g_registered_type_info_get_type_name),
5593         (g_registered_type_info_get_type_init),
5594         (g_struct_info_get_n_fields), (g_struct_info_get_field),
5595         (g_struct_info_get_n_methods), (g_struct_info_get_method),
5596         (find_method), (g_struct_info_find_method),
5597         (g_enum_info_get_n_values), (g_enum_info_get_value),
5598         (g_object_info_get_parent), (g_object_info_get_type_name),
5599         (g_object_info_get_type_init), (g_object_info_get_n_interfaces),
5600         (g_object_info_get_interface), (g_object_info_get_n_fields),
5601         (g_object_info_get_field), (g_object_info_get_n_properties),
5602         (g_object_info_get_property), (g_object_info_get_n_methods),
5603         (g_object_info_get_method), (g_object_info_find_method),
5604         (g_object_info_get_n_signals), (g_object_info_get_signal),
5605         (g_object_info_get_n_vfuncs), (g_object_info_get_vfunc),
5606         (g_object_info_get_n_constants), (g_object_info_get_constant),
5607         (g_interface_info_get_n_prerequisites),
5608         (g_interface_info_get_prerequisite),
5609         (g_interface_info_get_n_properties),
5610         (g_interface_info_get_property), (g_interface_info_get_n_methods),
5611         (g_interface_info_get_method), (g_interface_info_find_method),
5612         (g_interface_info_get_n_signals), (g_interface_info_get_signal),
5613         (g_interface_info_get_n_vfuncs), (g_interface_info_get_vfunc),
5614         (g_interface_info_get_n_constants),
5615         (g_interface_info_get_constant), (g_property_info_get_flags),
5616         (g_signal_info_get_flags), (g_signal_info_get_class_closure),
5617         (g_signal_info_true_stops_emit), (g_vfunc_info_get_flags),
5618         (g_vfunc_info_get_offset), (g_vfunc_info_get_signal),
5619         (g_constant_info_get_value), (g_union_info_get_n_fields),
5620         (g_union_info_get_field), (g_union_info_get_n_methods),
5621         (g_union_info_get_method), (g_union_info_is_discriminated),
5622         (g_union_info_get_discriminator_offset),
5623         (g_union_info_get_discriminator):
5624         * src/ginvoke.c: (g_function_info_invoke):
5625         * src/girepository.c: (g_irepository_register),
5626         (g_irepository_unregister), (g_irepository_get_default),
5627         (count_interfaces), (g_irepository_get_n_infos), (find_interface),
5628         (g_irepository_get_info), (g_irepository_find_by_name),
5629         (g_irepository_get_shared_library),
5630         (g_irepository_build_search_path), (g_irepository_register_file),
5631         (g_irepository_error_quark):
5632         * src/girepository.h:
5633         * src/gmetadata.c: (g_metadata_get_dir_entry),
5634         (g_metadata_check_sanity), (validate_header),
5635         (validate_array_type_blob), (validate_iface_type_blob),
5636         (validate_param_type_blob), (validate_error_type_blob),
5637         (validate_type_blob), (validate_arg_blob),
5638         (validate_signature_blob), (validate_function_blob),
5639         (validate_callback_blob), (validate_constant_blob),
5640         (validate_value_blob), (validate_field_blob),
5641         (validate_property_blob), (validate_signal_blob),
5642         (validate_vfunc_blob), (validate_struct_blob),
5643         (validate_enum_blob), (validate_object_blob),
5644         (validate_interface_blob), (validate_errordomain_blob),
5645         (validate_union_blob), (validate_blob), (validate_directory),
5646         (validate_annotations), (g_metadata_validate), (_g_metadata_init),
5647         (g_metadata_new_from_memory), (g_metadata_new_from_const_memory),
5648         (g_metadata_new_from_mapped_file), (g_metadata_free),
5649         (g_metadata_set_module), (g_metadata_get_namespace):
5650         * src/gmetadata.h:
5651         * tests/Makefile.am:
5652         * tests/invoke/Makefile.am:
5653         * tests/invoke/invoke-namespace-find.sh:
5654         * tests/invoke/invoke.c: (main):
5655
5656         Add a namespace/shared library mapping. fixes #313268.
5657
5658 2007-12-03  Johan Dahlin  <johan@gnome.org>
5659
5660         * src/gidlparser.c (parse_type_internal): Disable char/gchar and
5661         guchar for now.
5662
5663 2007-11-30  Jürg Billeter  <j@bitron.ch>
5664
5665         * configure.ac:
5666         * src/Makefile.am:
5667         * src/clexer.l:
5668         * src/cparser.y:
5669         * src/gen-introspect.c: (g_idl_node_cmp), (g_igenerator_new),
5670         (g_igenerator_write_inline), (g_igenerator_write),
5671         (g_igenerator_write_indent), (g_igenerator_write_unindent),
5672         (field_generate), (value_generate), (constant_generate),
5673         (property_generate), (function_generate), (vfunc_generate),
5674         (signal_generate), (interface_generate), (struct_generate),
5675         (union_generate), (boxed_generate), (enum_generate),
5676         (node_generate), (module_generate), (get_type_from_type_id),
5677         (str_replace), (g_igenerator_process_properties),
5678         (g_igenerator_process_signals), (g_igenerator_process_types),
5679         (get_type_from_ctype), (g_igenerator_process_function_symbol),
5680         (g_igenerator_process_unregistered_struct_typedef),
5681         (g_igenerator_process_struct_typedef),
5682         (g_igenerator_process_union_typedef),
5683         (g_igenerator_process_enum_typedef),
5684         (g_igenerator_process_function_typedef),
5685         (g_igenerator_process_constant), (g_igenerator_process_symbols),
5686         (g_igenerator_add_symbol), (g_igenerator_is_typedef),
5687         (g_igenerator_generate), (main), (csymbol_new),
5688         (csymbol_get_const_boolean), (ctype_new), (ctype_copy),
5689         (cbasic_type_new), (ctypedef_new), (cstruct_new), (cunion_new),
5690         (cenum_new), (cpointer_new), (carray_new), (cfunction_new),
5691         (eat_hspace), (eat_line), (read_identifier),
5692         (g_igenerator_parse_macros):
5693         * src/gen-introspect.h:
5694
5695         Import gen-introspect to generate introspection information by
5696         parsing C headers.
5697
5698 2007-11-30  Jürg Billeter  <j@bitron.ch>
5699
5700         * src/gidlnode.c: (g_idl_node_new): support creating callback nodes
5701
5702 2007-11-30  Jürg Billeter  <j@bitron.ch>
5703
5704         * src/gidlparser.c: (end_element_handler): Don't leave requires
5705         state too early.
5706
5707 2007-11-29  Johan Dahlin  <johan@gnome.org>
5708
5709         * src/gidlparser.c (parse_type_internal): Add char,
5710         gchar and guchar to the builtin types.
5711
5712 2007-11-26  Johan Dahlin  <johan@gnome.org>
5713
5714         * src/ginfo.c: (g_object_info_get_type_name),
5715         (g_object_info_get_type_init):
5716         * src/girepository.c: (g_irepository_is_registered):
5717         * src/girepository.h:
5718
5719         Add g_object_info_get_type_name, g_object_info_get_type_init and
5720         g_irepository_is_registered.
5721
5722 2006-08-14  Jürg Billeter  <j@bitron.ch>
5723
5724       * src/gidlparser.c: (end_element_handler): Don't leave
5725         namespace and implements states too early.
5726         Fixes #351264
5727
5728 2007-11-26  Johan Dahlin  <johan@gnome.org>
5729
5730         * src/gmetadata.c (validate_struct_blob):
5731         pass blob_type to validate_function_blob instead of
5732         hard-coding BLOB_TYPE_STRUCT.
5733
5734         Patch by Torsten Schoenfeld, fixes #314190
5735
5736 2006-10-03  Torsten Schoenfeld  <tsch@cvs.gnome.org>
5737
5738         * src/compiler.c, src/generate.c, src/gidlnode.c,
5739         src/gidlparser.c, src/ginfo.c, src/girepository.c,
5740         tests/invoke/invoke.c, test/invoke/testfns.c: Hush compiler
5741         warnings about return values, signedness mismatches, unused
5742         variables, and unhandles enum values in switch statements.
5743
5744         * tests/invoke/Makefile.am: Don't install the invoke test program.
5745         Add -I ../../src to the cflags used for the test functions files.
5746
5747 2005-08-31  Torsten Schoenfeld  <tsch@cvs.gnome.org>
5748
5749         * src/girepository.h: Export g_invoke_error_quark.
5750
5751 2005-08-31  Torsten Schoenfeld  <tsch@cvs.gnome.org>
5752
5753         * src/ginvoke.c: Remove the fallback implementation of
5754         g_function_info_invoke since we now formally depend on libffi.
5755
5756 2005-07-25  Matthias Clasen  <mclasen@redhat.com>
5757
5758         * src/Makefile, tests/Makefile, tests/invoke/Makefile:
5759         Remove these files from cvs, as they are now generated.
5760
5761         * src/gmetadata.c (validate_iface_type_blob): Don't
5762         complain if blob->pointer is not set, since that
5763         happens for enum and flag types.  (#308935, Gustavo
5764         Carneiro)
5765
5766         * Commit an autoconf-conversion patch by
5767         Gustavo Carneiro (#308708)
5768
5769 2005-05-24  Matthias Clasen  <mclasen@redhat.com>
5770
5771         * src/compiler.c (main): Use it here to validate
5772         the generated metadata.
5773
5774         * src/gmetadata.[hc]: Add code to validate a
5775         metadata blob.
5776
5777         * metadata-format.txt: Updates
5778
5779 2005-05-22  Matthias Clasen  <mclasen@redhat.com>
5780
5781         * tests/*: Add struct offsets to field and vfunc
5782         elements.
5783
5784         * src/generate.c (write_vfunc_info): Write offset
5785         information for vfuncs.
5786
5787         * src/gidlnode.c (g_idl_node_build_metadata): Write
5788         the struct offsets into the metadata.
5789
5790         * src/gidlparser.c: Parse the offset attributes of
5791         field and vfunc elements.
5792
5793         * src/gidlnode.h: Add offset members to field and
5794         vfunc nodes.
5795
5796 2005-05-21  Matthias Clasen  <mclasen@redhat.com>
5797
5798         * TODO: Updates.
5799
5800         * gidl.dtd: Updates.
5801
5802         * src/g-idl-offsets.pl: A perl script which reads a .gidl
5803         file, creates, compiles and runs a C file, and folds the
5804         resulting struct offsets back into the .gidl file.
5805
5806 2005-05-20  Matthias Clasen  <mclasen@redhat.com>
5807
5808         * src/gidlparser.c (start_field): Make fields in objects
5809         work.
5810
5811         * src/gidlmodule.c: Include string.h
5812
5813         * TODO: Updates.
5814         :
5815
5816         * metadata-format.txt: Cleanup basic types.
5817         * src/*: Adapt to the changes.
5818         * tests/*: Adapt to the changes.
5819         * examples/gdk-pixbuf.gidl: Adapt to the changes.
5820
5821         * src/gidlnode.c (g_idl_node_get_size): Report the correct
5822         size for enum blobs.
5823         (g_idl_node_get_full_size): Report the correct size for
5824         function blobs.
5825
5826         * src/gidlmodule.c (g_idl_module_build_metadata): Add some
5827         error checking for blob sizes.
5828
5829 2005-05-19  Matthias Clasen  <mclasen@redhat.com>
5830
5831         * src/gidlnode.c (g_idl_node_build_metadata): Correctly handle
5832         interface types for which is_pointer is FALSE, e.g. enums.
5833
5834         * src/gidlnode.c (g_idl_node_get_full_size)
5835         * src/gidlparser.c (parse_type_internal):
5836         * src/generate.c (write_type_info): Support unspecialized
5837         lists, hashtables and errors. Also emit a '*' after these.
5838
5839         * TODO: Updates
5840
5841 2005-05-17  Matthias Clasen  <mclasen@redhat.com>
5842
5843         * TODO: Updates
5844
5845         * metadata-format.txt: Cleanups by Maciej Katafiasz.
5846
5847 2005-05-15  Matthias Clasen  <mclasen@redhat.com>
5848
5849         * src/*.c: Change the directory to be addressed by
5850         1-based indexes, and use an index of zero to mean
5851         'no object'.
5852
5853 2005-05-15  Matthias Clasen  <mclasen@redhat.com>
5854
5855         * tests/roundtrips.sh (SIMPLE_TESTS): Add union.test.
5856
5857         * tests/union.test: Add a union test.
5858
5859         * src/generate.c: Handle unions.
5860
5861         * src/girepository.h:
5862         * src/ginfo.c: Add GIUnionInfo and functions to access it.
5863
5864         * src/gidlnode.c: Handle GIdlNodeUnion nodes.
5865
5866         * src/gidlparser.c (start_union): Parse <union> elements.
5867
5868         * src/gidlnode.h: Add a GIdlNodeUnion.
5869
5870         * gidl.dtd: Add a <union> element.
5871
5872         * src/gmetadata.c (g_metadata_check_sanity): Check
5873         union_blob_size.
5874
5875         * src/gmetadata.h: Add union_blob_size to Header,
5876         add a UnionBlob.
5877
5878         * metadata-format.txt: Add a UnionBlob.
5879
5880 2005-05-13  Matthias Clasen  <mclasen@redhat.com>
5881
5882         * tests/*: Update testcases.
5883
5884         * src/generate.c (write_callable_info): Don't forget to
5885         write transfer and null-ok attributes for return types
5886         and parameters.
5887
5888         * src/girepository.h:
5889         * src/ginfo.c (g_callable_info_may_return_null):
5890         New function to find out if a function may return NULL.
5891
5892         * src/compiler.c (format_output): Make the generated
5893         C code compile.
5894
5895         * README: Point to a recent libffi snapshot.
5896
5897         * tests/invoke/*: Some invoke tests.
5898
5899         * src/Makefile: Add ginvoke.c and the necessary
5900         libffi information.
5901
5902         * src/girepository.h (g_function_info_invoke): Add
5903         a GError argument.
5904
5905         * src/ginvoke.c (g_function_info_invoke): Initial
5906         implementation of invoke functionality based on libffi.
5907
5908         * src/gidlnode.c (g_idl_node_build_metadata): Pass the
5909         strings and types hash tables in the right order when
5910         recursing.
5911         (find_entry_node): Free the name parts.
5912
5913 2005-05-12  Johan Dahlin  <johan@gnome.org>
5914
5915         * src/generate.c: Generate consistent end tags.
5916
5917         * tests/*: Update
5918
5919 2005-05-12  Matthias Clasen  <mclasen@redhat.com>
5920
5921         * TODO: Updates
5922
5923         * src/gidlparser.c (start_function): Actually add
5924         methods to objects.  (Steven Walter)
5925
5926         * src/girepository.h:
5927         * src/ginfo.c: Rename Transfer and Direction to
5928         GITransfer and GIDirection. (Torsten Schoenfeld)
5929
5930         * tests/*: Make tests work with the changes in name
5931         handling.
5932
5933         * src/gidlnode.c (find_entry_node): Parse qualified
5934         names and generate xref nodes for them if needed. Don't
5935         require all modules to be loaded any more.
5936
5937         * src/gidlmodule.c (g_idl_module_build_metadata): Choke
5938         on '.' in names.
5939
5940         * src/ginfo.c (g_object_info_get_parent): Return NULL
5941         if blob->parent is 0. Still need to make sure index
5942         0 is not used.
5943
5944         * src/generate.c: Generate qualified names when
5945         referring to non-local types. Emit transfer attribute
5946         for return types.
5947
5948         * src/compiler.c (format_output): Put the function
5949         attributes where gcc accepts them.
5950
5951 2005-05-11  Matthias Clasen  <mclasen@redhat.com>
5952
5953         * src/compiler.c (main): Add a --verbose cmdline option
5954         and only log messages if it is specified.
5955
5956         * src/gidlnode.h:
5957         * src/gidlnode.c (init_stats, dump_stats): Collect some
5958         statistics on string and type sharing.
5959
5960         * src/gidlmodule.c (g_idl_module_build_metadata): Use
5961         g_message() instead of fprintf().
5962
5963         * src/gidlnode.c (g_idl_node_free): Make this more robust.
5964         (g_idl_node_get_size): Implement for structs.
5965         (g_idl_node_get_full_size): Handle parent being NULL.
5966         (serialize_type): Handle lookup failures more gracefully.
5967
5968 2005-05-10  Matthias Clasen  <mclasen@redhat.com>
5969
5970         * src/gidlnode.c (g_idl_node_get_full_size): Correct the
5971         size calculation for 2-parameter types and for objects.
5972
5973         * src/compiler.c: Add a cmdline option for debug output
5974         and install a log handler to implement it.
5975         * src/gidlnode.c: Add some debug spew.
5976
5977         * TODO: Updates
5978
5979         * src/gidlmodule.c (g_idl_module_build_metadata): Don't
5980         forget to count the module name when calculating the
5981         required size for the metadata.
5982
5983         * src/gidlnode.c:
5984         * src/gidlparser.c: Fix compiler warnings.
5985
5986 2005-05-09  Matthias Clasen  <mclasen@redhat.com>
5987
5988         * src/compiler.c (main): Free the option context.
5989
5990         * gidl.dtd: Clean up handling of names. All elements
5991         have a "name", only the elements corresponding to
5992         actual callable functions (function, method, constructor),
5993         have an additional "symbol" attribute holding the
5994         dlsym()-able function name.
5995
5996         * src/generate.c: Adapt to generate xml matching the
5997         new dtd.
5998
5999         * src/gidlparser.c:
6000         * src/gidlnode.c: Adapt to parse the new dtd.
6001
6002         * tests/*.test: Adjust to the new dtd.
6003
6004         * metadata-format.txt:
6005         * src/gmetadata.h: Remove the short_name field
6006         from the ValueBlob.
6007         * src/gmetadata.c: Shrink size of ValueBlob to 12.
6008         * src/girepository.h:
6009         * src/ginfo.c (g_value_info_get_short_name): Removed
6010
6011 2005-05-09  Matthias Clasen  <mclasen@redhat.com>
6012
6013         * gidl.dtd: Allow constructors for boxed types,
6014         patch by Jonathan Blandford.
6015
6016
6017 2005-05-09  Matthias Clasen  <mclasen@redhat.com>
6018
6019         * --- Initial import ---