Skip to content

Commit e1a30b6

Browse files
authored
Fix php linting, integer -> int (#290)
* Change integer type to int in PHP type mappings Updated PHP type mappings for GValue types to use 'int' instead of 'integer'. * Change integer type hints to int in ImageAutodoc.php
1 parent 6296806 commit e1a30b6

2 files changed

Lines changed: 65 additions & 65 deletions

File tree

examples/generate_phpdoc.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -20,15 +20,15 @@
2020
# map a Python gtype to PHP argument type names
2121
gtype_to_php_arg = {
2222
GValue.gbool_type: 'bool',
23-
GValue.gint_type: 'integer',
23+
GValue.gint_type: 'int',
2424
GValue.gdouble_type: 'float',
2525
GValue.gstr_type: 'string',
2626
GValue.refstr_type: 'string',
2727
GValue.genum_type: 'string',
28-
GValue.gflags_type: 'integer',
28+
GValue.gflags_type: 'int',
2929
GValue.gobject_type: 'string',
3030
GValue.image_type: 'Image',
31-
GValue.array_int_type: 'integer[]|integer',
31+
GValue.array_int_type: 'int[]|int',
3232
GValue.array_double_type: 'float[]|float',
3333
GValue.array_image_type: 'Image[]|Image',
3434
GValue.blob_type: 'string',
@@ -39,12 +39,12 @@
3939
# php result type names are different, annoyingly, and very restricted
4040
gtype_to_php_result = {
4141
GValue.gbool_type: 'bool',
42-
GValue.gint_type: 'integer',
42+
GValue.gint_type: 'int',
4343
GValue.gdouble_type: 'float',
4444
GValue.gstr_type: 'string',
4545
GValue.refstr_type: 'string',
4646
GValue.genum_type: 'string',
47-
GValue.gflags_type: 'integer',
47+
GValue.gflags_type: 'int',
4848
GValue.gobject_type: 'string',
4949
GValue.image_type: 'Image',
5050
GValue.array_int_type: 'array',

0 commit comments

Comments
 (0)