odil icon indicating copy to clipboard operation
odil copied to clipboard

Members initialization in AssociationParameters

Open cguebert opened this issue 9 years ago • 5 comments

There are currently 3 constructors for AssociationParameters, but not all initialize all the class members. We can factor using class member initializers. Also, calling default constructors for members is not necessary.

cguebert avatar Oct 19 '16 13:10 cguebert

Coverage Status

Coverage increased (+0.02%) to 84.693% when pulling fdf64eb1e9b79932cf76e3a22126ac912f9d9dd1 on cguebert:master into a1be327e2f8caab3dabe04e0d025cbfc53390410 on lamyj:master.

coveralls avatar Oct 19 '16 13:10 coveralls

Sadly, I can't merge this yet: I still need to support Ubuntu 12.04 and its GCC 4.6, which does not have in-class initializers. I'll leave this PR open for now, since the official support (and hence Odil's support) will end at in March 2017.

lamyj avatar Oct 20 '16 08:10 lamyj

At least we should fix the bug of _maximum_number_operations_invokedand _maximum_number_operations_performed not being initialized.

cguebert avatar Oct 21 '16 09:10 cguebert

Initialization is fixed in b3d1518 while waiting for Ubuntu 12.04 to be end-of-life.

lamyj avatar Oct 26 '16 14:10 lamyj

@lamyj do you think this one could be merged?

ferdymercury avatar Oct 11 '23 09:10 ferdymercury