Bug 54874 - further storage refactoring: be more variant-based internally
Summary: further storage refactoring: be more variant-based internally
Status: RESOLVED FIXED
Alias: None
Product: Telepathy
Classification: Unclassified
Component: mission-control (show other bugs)
Version: unspecified
Hardware: Other All
: medium normal
Assignee: Simon McVittie
QA Contact: Telepathy bugs list
URL: http://cgit.freedesktop.org/~smcv/tel...
Whiteboard:
Keywords: patch
Depends on: 54780
Blocks:
  Show dependency treegraph
 
Reported: 2012-09-13 15:17 UTC by Simon McVittie
Modified: 2013-10-31 14:49 UTC (History)
1 user (show)

See Also:
i915 platform:
i915 features:


Attachments
mcd_keyfile_set_value: implement in terms of a new mcd_keyfile_set_variant (7.55 KB, patch)
2013-10-29 14:27 UTC, Simon McVittie
Details | Splinter Review
mcd_keyfile_escape_value: implement in terms of mcd_keyfile_escape_variant (3.27 KB, patch)
2013-10-29 14:29 UTC, Simon McVittie
Details | Splinter Review
mcd_keyfile_get_value: implement in terms of a new mcd_keyfile_get_variant (12.52 KB, patch)
2013-10-29 14:30 UTC, Simon McVittie
Details | Splinter Review

Description Simon McVittie 2012-09-13 15:17:56 UTC
This is part 5 of my account storage refactoring megabranch. It's probably non-critical, although beware that I haven't yet tested part 6 without this refactoring applied.
Comment 1 Will Thompson 2012-11-07 17:40:45 UTC
This looks okay, but it doesn't seem to improve much in and of itself: it moves the conversions to a different place. (I guess the ultimate goal is to bubble them right out so they go away entirely.)
Comment 2 Simon McVittie 2012-11-08 11:15:44 UTC
(In reply to comment #1)
> (I guess the ultimate goal is to bubble them right out so they
> go away entirely.)

Yes. I could try rebasing Bug #54875 to happen before this, and not merge this one until it enables something practically-useful, if you'd prefer?
Comment 3 Simon McVittie 2013-10-29 14:27:25 UTC
Created attachment 88301 [details] [review]
mcd_keyfile_set_value: implement in terms of a new  mcd_keyfile_set_variant

---

Not needed for Bug #54874, but provides symmetry with the one above.
Comment 4 Simon McVittie 2013-10-29 14:29:32 UTC
Created attachment 88302 [details] [review]
mcd_keyfile_escape_value: implement in terms of  mcd_keyfile_escape_variant

It was previously the other way round.

Similarly, implement mcd_storage_coerce_variant_to_value in terms of
mcd_keyfile_escape_variant.

---

Also not needed for Bug #54875, but it avoids some indirection if the previous patch is applied.

I've just noticed that the last patch band should actually have been part of the previous patch - not that it matters much if both are merged.
Comment 5 Simon McVittie 2013-10-29 14:30:25 UTC
Created attachment 88303 [details] [review]
mcd_keyfile_get_value: implement in terms of a new  mcd_keyfile_get_variant

---

This is actually the only one needed for Bug #54875. I thought I'd already attached this - please s/above/below/ in the previous comments :-)
Comment 6 Guillaume Desmottes 2013-10-29 14:31:24 UTC
Comment on attachment 88301 [details] [review]
mcd_keyfile_set_value: implement in terms of a new  mcd_keyfile_set_variant

Review of attachment 88301 [details] [review]:
-----------------------------------------------------------------

++
Comment 7 Guillaume Desmottes 2013-10-31 08:10:41 UTC
Comment on attachment 88302 [details] [review]
mcd_keyfile_escape_value: implement in terms of  mcd_keyfile_escape_variant

Review of attachment 88302 [details] [review]:
-----------------------------------------------------------------

++
Comment 8 Guillaume Desmottes 2013-10-31 08:12:17 UTC
Comment on attachment 88303 [details] [review]
mcd_keyfile_get_value: implement in terms of a new  mcd_keyfile_get_variant

Review of attachment 88303 [details] [review]:
-----------------------------------------------------------------

++
Comment 9 Simon McVittie 2013-10-31 14:49:40 UTC
Fixed in git for 5.17.0, thanks.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.