← Back to team overview

kicad-developers team mailing list archive

Re: [PATCH] CPolyLine -> SHAPE_POLY_SET refactor

 

Hi, guys!

Sorry for the late reply, Easter Week out of home.


2017-04-14 15:09 GMT+02:00 jp charras <jp.charras@xxxxxxxxxx>:

>
> OK.
> I reverted the change in seg.h (looking to me as a old seg.h version
> committed by mistake)
> in my commit cbb5708c365025df67161a7fa8e29b3925e39741,
> and updated a few comments.
>

It was not an old version, I changed it. The reason behind the change was
this comment in shape_line_chain.h, in Segment function:

Returns a segment referencing to the segment (index) in the line chain.
Modifying ends of the returned segment will modify corresponding points in
the line chain.

As well as this (maybe old?) one in SEG class:

These are references to an object the segment belongs to (e.g. a line chain)
or references to locally stored points (m_a, m_b).

I understood that SEG class should reference the points passed, so I just
modified the class.

I should have asked, sorry! Anyway, should we modify those comments to
actually reflect what the code does?

Thanks for pointing this out and for the fix, JP.

Best,
Alejandro

Follow ups

References