Opened 12 years ago
Closed 12 years ago
#1829 closed discussion (fixed)
Cannot find aliased package functions
Reported by: | Owned by: | Martin Sjölund | |
---|---|---|---|
Priority: | high | Milestone: | 1.9.0 |
Component: | Frontend | Version: | trunk |
Keywords: | Cc: |
Description
I have this simple code that I don't understand why it fails, I'm using aliased imports in other places without problem but I had one issue that I managed to get down to a simple program.
Replacing the call to P.f()
with PKG.f()
or compiling without +g=MetaModelica
doesn't cause compiler failure.
package PKG function f output Integer result; algorithm result := 1; end f; end PKG; package PKG2 package P = PKG; // This also fails: // import P = PKG; function test algorithm P.f(); end test; end PKG2; model M algorithm PKG2.test(); end M;
Result:
> omc +g=MetaModelica P.mo Error processing file: P.mo Error: Failed to instantiate function .P.f in scope PKG2.test Error: Error occurred while flattening model M # Error encountered! Exiting... # Please check the error message and the flags. Execution failed!
Change History (2)
comment:1 by , 12 years ago
Owner: | changed from | to
---|---|
Status: | new → accepted |
comment:2 by , 12 years ago
Component: | Backend → Frontend |
---|---|
Milestone: | → 1.9.0 |
Resolution: | → fixed |
Status: | accepted → closed |
Note:
See TracTickets
for help on using tickets.
Fixed in r13029. Regression test added.