2020-04-21 Rico Tzschichholz Release 0.40.21 tests: Fix make dist atk-1.0: Adjust for upstream revert of Implementor using G_DEFINE_INTERFACE See https://gitlab.gnome.org/GNOME/atk/commit/96d13ae47f6f77445483ee8a0d7d6569a95f35bf webkit2gtk-4.0: Update to 2.28.0 (Sync from 0.48.x) Fixes https://gitlab.gnome.org/GNOME/vala/issues/974 gtk+-3.0: Update to 3.24.18 gio-2.0: Add "async_result_pos" attributes to *.call_with_unix_fd_list() Fixes https://gitlab.gnome.org/GNOME/vala/issues/340 girparser: Improve detection of AsyncReadyCallback/AsyncResult parameters girparser: Drop special handling of GLib.Data, GLib.PtrArray and GLib.String girparser: Move special handling for certain parameters to process_callable() - Detect delegate throwing error when GLib.Error out-parameter exists - Mark method as async based on finding an AsyncReadyCallback parameter - Apply null-literal default-value for trailing GLib.Cancellable? parameters codegen: Fix default of CCode.pos for parameters in async methods 2020-04-21 Princeton Ferro vala: Ensure non-empty argument list for "disconnect" before accessing it Avoids an internal assertion on accessing an empty collection. 2020-04-21 Rico Tzschichholz tests: Add "version check" tests to increase coverage Use several symbols from glib-2.0 >= 2.50 and refer to custom pkg-config file defining 2.48.0 as version. vala: Quote symbol on report by version attribute check vala: Perform version check for types of non-external variable declarations vala: Don't perform version check on internal lambda method vala: Check assigned handler of dynamic signal before proceeding further This fixes criticals if an errornous expression was given. codegen: Fix base-access to non-abstract/non-virtual properties Don't unconditionally try to access vfuncs and actually emit assignments. Fixes https://gitlab.gnome.org/GNOME/vala/issues/204 codegen: Reduce code duplications when generation base-access codegen: Use specified indices to access multidimensional array constants This fixes compile issues together with -Waggressive-loop-optimizations and warnings with -Warray-bounds. Fixes https://gitlab.gnome.org/GNOME/vala/issues/905 codegen: Correctly handle signals returning real non-nullable struct Fixes https://gitlab.gnome.org/GNOME/vala/issues/466 codegen: Use get_value_*_function() in GSignalModule.generate_marshaller() This makes sure to pick up the intended function like the generated ones for fundamental classes. Fixes https://gitlab.gnome.org/GNOME/vala/issues/468 codegen: Add support for delegate parameters in signals Fixes https://gitlab.gnome.org/GNOME/vala/issues/205 2020-04-21 Andrea Del Signore codegen: Fix binary 'in' operator on array with boxed value-typed needle See https://gitlab.gnome.org/GNOME/vala/issues/951 2020-04-21 Princeton Ferro parser: Handle incomplete expression statements Incomplete expression statements are parsed as expression statements now, rather than local variable declarations. This primarily affects incomplete member access expressions at the end of blocks. vala: Don't use possibly uninitialized backing field of package_name Don't check _package_name directly, which may be null at the time installed_version is accessed. This fixes a bug where Vala wouldn't generate errors when using symbols that are unavailable for a package version. Introduced by 7f0e90a5c34f437b7ab8f9197a9d42fc835b1a60 Fixes https://gitlab.gnome.org/GNOME/vala/issues/971 2020-04-21 Rico Tzschichholz vala: Fix cleaning of output in CodeContext.pkg_config_modversion() glib-2.0: Guard Pid.to_string() with GLIB_2_50 to deal with G_PID_FORMAT Otherwise building with glib-2.0 < 2.50 breaks due availability check of GLib.Pid.FORMAT. gstreamer-app-1.0: Don't merge Src.push_buffer_*() signal with its method Fixes https://gitlab.gnome.org/GNOME/vala/issues/968 vala: Set default_construction_method in semantic-analyzer check if required Doing this in the parser is not reasonable while this is clearly a sematic requirement. tests: Add "Bus/DBusConnection.get_proxy*()" tests to increase coverage codegen: Don't pass CCodeCastExpression to NULL-aware free macro This resulted in invalid C code: error: lvalue required as left operand of assignment Fixes https://gitlab.gnome.org/GNOME/vala/issues/953 2020-04-21 Corentin Noël tests: Add "g-interface-info" dbus test to increase coverage tests: Extend "DBus signals" test to increase coverage This adds code coverage for generating multiple signals, tests for arrays and ensures that the private signals are not leaking. 2020-04-21 Rico Tzschichholz codegen: Correctly handle transformation of translated string-literal constants The required header includes were not emited to the correct declaration space. vala: Parse standalone integer/real literals as expression statement Issue an error in the semantic check to forbid such statements. Parsing such an errornous expression-statement failed since 5464767cfa5a8dbbc5f46293693ca627b8fcc46d Fixes https://gitlab.gnome.org/GNOME/vala/issues/961 tests: Extend "array foreach" test to increase coverage vala: Consider boolean types are compatible with each other tests: Add "expression as argument" tests to increase coverage codegen: Correct field declaration for captured inline-allocated array Also pass proper size to memset for local temp variables of inline-allocated arrays in asynchronous context. Fixes https://gitlab.gnome.org/GNOME/vala/issues/954 codegen: Don't free value if property setter takes ownership Correctly handle owned property accessor in object initializer. In addition to c0e955db075d3d155782c167a0abb81e0dce5f59 See https://gitlab.gnome.org/GNOME/vala/issues/953 tests: Add "local clash with implicit this" test to increase coverage tests: Add "switch enum" test to increase coverage codegen: Avoid critical trying to serialize an unsupported type to Variant Fixes https://gitlab.gnome.org/GNOME/vala/issues/952 vala: Handle all ctors and dtors in CodeWriter vala: Handle unlock() statement in CodeWriter 2020-04-21 Simon Werbeck vala: Support struct initializer list in non-constant array A struct initializer list contained in an array initializer list is now transformed to a struct creation expression. The pre-existing logic ensures that constant expressions are not transformed. Fixes https://gitlab.gnome.org/GNOME/vala/issues/949 2020-04-21 Rico Tzschichholz codegen: Append initializer for "_*_size_" of array field in internal struct Fixes https://gitlab.gnome.org/GNOME/vala/issues/914 tests: Add "throw in loops" tests to increase coverage codegen: Correctly access captured parameter in precondition of method Fixes https://gitlab.gnome.org/GNOME/vala/issues/144 codegen: Emit postconditions before free'ing local variables It was possible to cause segmentation-faults or use-after-free errors. codegen: Don't append unreachable clean-up section of Block Found by -Werror=unreachable-code See https://gitlab.gnome.org/GNOME/vala/issues/838