← Back to team overview

kicad-developers team mailing list archive

Re: Edit text and graphic properties behavior

 

Hi Simon,

I think one of the original justifications of dyn_cast<> was that it was faster.  Do I have that wrong, or do we not believe it to be material?

(Other than that I’d love to get rid of it.  It’s bitten me more than once.)

Cheers,
Jeff.


> On 16 Oct 2018, at 17:38, Simon Richter <Simon.Richter@xxxxxxxxxx> wrote:
> 
> Hi,
> 
> On 10/16/2018 06:19 PM, Wayne Stambaugh wrote:
> 
>>> The “Footprint graphic items” bug was a dyn_cast when a dynamic_cast was needed (dyn_cast doesn’t handle inheritance).
> 
>> Do you want me to file a bug report on this or are you going to fix it
>> right away?
> 
> I have a patch that eliminates dyn_cast<> and replaces all instances
> with dynamic_cast<>.
> 
> The downside is that since dyn_cast<> explicitly ignores inheritance in
> the case of VIA -> TRACK and ZONE -> TRACK, I had to create a new TRACE
> class and make TRACK abstract, which means that Python scripts will need
> to be adjusted, or we need a compatibility layer here.
> 
> I'm planning to submit this to the 6.0 branch once it opens.
> 
>   Simon
> 
> _______________________________________________
> Mailing list: https://launchpad.net/~kicad-developers
> Post to     : kicad-developers@xxxxxxxxxxxxxxxxxxx
> Unsubscribe : https://launchpad.net/~kicad-developers
> More help   : https://help.launchpad.net/ListHelp



Follow ups

References