GNOME Bugzilla – Bug 631787
Incorrect behaviour of "+=" operator with int-value HashMaps
Last modified: 2018-05-22 13:45:50 UTC
Hello, attaching a simple testcase showing the problem (thanks, Frederik!). map["key"] = map["key"] + 1 works, while map["key"] += 1 not (nor ++, see #631781). Kindly, David
Created attachment 172030 [details] += operator fails with int-value HashMap
Confirming, wrong C code is generated.
*** Bug 631781 has been marked as a duplicate of this bug. ***
Created attachment 219039 [details] [review] Fix assignment operators for element access
Bug is still present in 0.24
(In reply to David Paleino from comment #1) > Created attachment 172030 [details] > += operator fails with int-value HashMap Segfault is not present as for 0.34, because map["foo"]++; is invalid syntax, as for Vala Code Generator. Tagged for 1.0 Release.
-- GitLab Migration Automatic Message -- This bug has been migrated to GNOME's GitLab instance and has been closed from further activity. You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.gnome.org/GNOME/vala/issues/135.