Opened 9 years ago

Closed 9 years ago

Last modified 9 years ago

#3577 closed defect (fixed)

Complete the implementation of copyClass API

Reported by: Adeel Asghar Owned by: Per Östlund
Priority: blocker Milestone: 1.9.4
Component: Interactive Environment Version:
Keywords: Cc:

Description

There are two issues with the API,

  1. It only works for a single class. If a class contains nested classes then the source info for them is copied from the source class which is bad.
  1. If the class is copied to a different scope then the elements of the class might need to be updated accordingly. One idea is to make the paths full e.g Interfaces.Pin p; should become Modelica.Electrical.Analog.Interfaces.Pin p;

Change History (6)

comment:1 by Per Östlund, 9 years ago

The first issue has been fixed in b1d0c1d. We now change all source infos in the copied class to <interactive>, with the lines offset with the enclosing class' start line (i.e. an element on line 4 in a class will have a source info that says <interactive>:4:...).

comment:2 by Adrian Pop, 9 years ago

Priority: highblocker

comment:3 by Per Östlund, 9 years ago

copyClass has now been changed in a64582d so that it tries to figure out the destination file of the copied class.

comment:4 by Francesco Casella, 9 years ago

Resolution: fixed
Status: newclosed

The problem that inspired this ticket (#3630) is solved after Per's commit.

comment:5 by Martin Sjölund, 9 years ago

Milestone: 1.9.41.9.4-1.9.x

Milestone renamed

comment:6 by Martin Sjölund, 9 years ago

Milestone: 1.9.4-1.9.x1.9.4

Milestone renamed

Note: See TracTickets for help on using tickets.