Bug 555712: Struct and union issues
authorAndreas Rottmann <a.rottmann@gmx.at>
Sat, 11 Oct 2008 21:16:57 +0000 (21:16 +0000)
committerJohan Dahlin <johan@src.gnome.org>
Sat, 11 Oct 2008 21:16:57 +0000 (21:16 +0000)
commit7b1e139cd77b60b37d2b1dadfe45855e7bf122e1
treed9b67de55369591a343b5d4f6f8e5cf4a093dc1f
parent59011ffa9f2d12cb0c087f451b5918be98d6022e
Bug 555712: Struct and union issues

2008-10-09  Andreas Rottmann  <a.rottmann@gmx.at>

    Bug 555712: Struct and union issues

    * giscanner/scannerparser.y (struct_declarator): Use information
    provided about the bit width of a field.
    * giscanner/transformer.py (Transformer._create_member): Pass the
    symbol's const_int member to the created field (it represents the
    bit width).
    * giscanner/girwriter.py (GIRWriter._write_field): Output 'bits'
    field attribute, if present.
    * giscanner/ast.py (Field): Add 'bits' member, specifying the
    width in bits of the field (only relevant for bitfields).
    * tests/*: Updated.

    * giscanner/transformer.py (Transformer._create_typedef_struct)
    (Transformer._create_typedef_union): Add calls to _create_struct()
    and _create_union(), respectively. This causes the scanner to
    generate output for fields of struct and union typedefs.
    * tests/*: Updated.

svn path=/trunk/; revision=667
ChangeLog
giscanner/ast.py
giscanner/girwriter.py
giscanner/scannerparser.y
giscanner/transformer.py
tests/scanner/utility-expected.gir
tests/scanner/utility.h