Index: mttroot/mtt/bin/trans/m/write_abg.m ================================================================== --- mttroot/mtt/bin/trans/m/write_abg.m +++ mttroot/mtt/bin/trans/m/write_abg.m @@ -3,10 +3,13 @@ ############################################################### ## Version control history ############################################################### ## $Id$ ## $Log$ +## Revision 1.2 1998/08/26 11:59:20 peterg +## Don't use strrep to remove[] +## ## Revision 1.1 1998/08/25 06:22:02 peterg ## Initial revision ## ############################################################### @@ -30,10 +33,14 @@ fprintf(fid,"\n# Subsystems and Ports\n"); i_port=0; for i=1:N eval(["[comp_type, name, cr, arg, repetitions] = ", system_name, "_cmp(i);"]); + ch=name(1); # First char of name + if (ch>="0")&&(ch<="9") # Its a numeral + name=["mtt",name]; # prefix by mtt + endif; if index(name,"[")==0 # Not a port fprintf(fid,"\n# Component %s\n", name); fprintf(fid,Sformat,system_name,name,"type",comp_type); fprintf(fid,Sformat,system_name,name,"cr",cr);