Skip to content

Commit

Permalink
- fixes for aliases to array types:
Browse files Browse the repository at this point in the history
  type Alias = Real[6]; 
  Alias x; // this variable had [6,6] dimension instead of correct [6].

git-svn-id: https://openmodelica.org/svn/OpenModelica/trunk@4069 f25d12d1-65f4-0310-ae8a-bbce733d8d8e
  • Loading branch information
adrpo committed Jun 2, 2009
1 parent a5467e7 commit 879bb91
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion Compiler/Inst.mo
Expand Up @@ -4344,7 +4344,11 @@ algorithm
(cache,(dims_1 as (_ :: _))) = getUsertypeDimensions(cache,env, mod, pre, cl, inst_dims, impl);
(cache,compenv,dae,csets_1,ty_1) = instVar2(cache,env, ci_state, mod, pre, csets, n, cl, attr, prot, dims_1, idxs,
inst_dims, impl, comment,io);
ty = makeArrayType(dims_1, ty_1);
// adrpo: 2009-06-02, change this below from
// ty_1 = makeArrayType(dims_1, ty_1);
// as this doubles the array dimension wrongy
// i.e. Real[X] wrongly becomes Real[X,X].
ty = ty_1;
then
(cache,compenv,dae,csets_1,ty);

Expand Down

0 comments on commit 879bb91

Please sign in to comment.