diff options
author | Jon Turney <jon.turney@dronecode.org.uk> | 2018-01-14 21:10:51 +0000 |
---|---|---|
committer | Jon Turney <jon.turney@dronecode.org.uk> | 2018-01-15 20:27:48 +0000 |
commit | 153a7fb33240dc04f459147b418f58e30d448d56 (patch) | |
tree | c6630331583be489fb47e9aa4815564b57f2328b /docs/markdown | |
parent | 8efdcca93063fb224c53ae2d6f57b8dacf082456 (diff) | |
download | meson-153a7fb33240dc04f459147b418f58e30d448d56.zip meson-153a7fb33240dc04f459147b418f58e30d448d56.tar.gz meson-153a7fb33240dc04f459147b418f58e30d448d56.tar.bz2 |
Fix unpickling of dynamic subclasses of ConfigToolDependency
This code isn't used as present: the actual objects we use and which get
pickled are either static subclasses of ConfigToolDependency, or special
purpos subclasses of Dependency which get attributes copied from an instance
of a dynamic subclass of ConfigToolDependency which is then discarded.
This is fortunate, as it doesn't work: the pickled reduction is a call to
the dynamic subclass's constructor, but the superclass constructors rely on
the environment object being fully initialized, which hasn't happened yet
during unpickling.
Avoid this by having a pickled reduction which is just a call to create the
dynamic subclass object, and relying on the default __setstate__ behavior to
unpickle the object's __dict__.
Diffstat (limited to 'docs/markdown')
0 files changed, 0 insertions, 0 deletions