13:49 <RAOF> What do you think of pulling the age() related bits into ClientBuffer; the implementation shouldn't be different between AndroidClientBuffer and GBMClientBuffer.
13:51 <RAOF> I'm leary of mixing interface and implementation there.
14:51 <racarr> RAOF: I kind of like pulling the age related bits in...(just catching backscroll)
14:51 <racarr> the mixing implementation and interface is a red flag though
14:51 <racarr> the other red flag is the
14:51 <racarr> implementation of the ageing semantics on the mock buffer with the expectations
14:51 <racarr> in one of the tests
14:51 <RAOF> Yeah, that's rather awkward.
14:51 <racarr> which says that really there is
14:51 <racarr> another object
14:51 <racarr> BufferAgeTracker (complete strawman name)
14:51 <racarr> and its an integration test
14:51 <racarr> but...eh
14:52 <racarr> I am not sure how strongly I feel about it
14:52 <duflu> racarr: Orange flag at most. If there's no real testing value gained by mocking systems code then I think it's often OK to mix implementation with interface
14:52 <racarr> Sure, orange flag :)
14:53 <racarr> Maybe Buffer has a member
14:53 <racarr> type BufferAge
14:54 <RAOF> ClientBuffer could well have a public uint32_t age, yes.
14:54 <duflu> On the other hand... being able to test code natively is preferable to mocking. And if you can do that, then you don't need to separate interface from implementation
14:54 <racarr> RAOF: No I mean a
14:54 <racarr> BufferAge age, and then the methods increment_age, mark_as_submitted, age()
14:54 <racarr> etc
14:54 <racarr> move to BufferAge definition
14:54 <racarr> and out of the platform code
14:55 <RAOF> Possibly. I *think* the Buffer might actually want to do something on mark_as_submitted(), though.
14:55 <racarr> duflu: Here the interface is seperated because it actually has multiple implementations
14:55 * duflu stops generalizing about code he hasn't seen yet
14:56 <racarr> RAOF: does it have to do with the age
14:56 <racarr> duflu: Hehe. my number 1 hobby!
14:56 <RAOF> racarr: No, not to do with age.
14:56 <racarr> RAOF: Then I would imagine
14:56 <duflu> Generally speaking... we should use Go.
14:56 <racarr> buffer.submit() does that thing and
14:56 <racarr> also calls buffer_age.mark_as_submitted()
14:56 <RAOF> racarr: The *age* interface doesn't actually have multiple implementations, though.
14:57 <racarr> RAOF: In what tense? Right now it does i.e. increment_age is implemented in the test, the android buffer and the gbm buffer
14:58 <racarr> so the idea is to just move the implementation to a single shared BufferAge type
14:58 <RAOF> racarr: In the sense that it's ever sensible to have different behaviour there.
14:58 <racarr> mm
14:58 <racarr> so I mean it's a concrete type
14:58 <racarr> its just to avoid mixing implementation in to the ClientBuffer API
14:59 <racarr> I guess there is still some :)
14:59 <RAOF> Alternatively, ClientBuffer abstract, AgeableBuffer concrete, {GBM,Android}ClientBuffer inherits from both?
15:00 <racarr> RAOF: Mm
15:01 <racarr> RAOF: Anyway...I don't feel strongly enough about any of these to feel like
15:01 <racarr> blocking on it...but maybe if you think one is a particularly good idea or europe has a good idea :)