rmariani@watmum.waterloo.edu (Rico Mariani) (04/28/88)
main()
{
printf("This is a test"
#line 20 "glorp"
);
printf("That was a test\n");
}
This works fine if the #line is not present.... but it generates
the following code otherwise:
;:ts=8
;main()
;{
public _main
_main:
link a5,#.2
movem.l .3,-(sp)
; printf("This is a test"
;#line 20 "glorp"
; );
pea .1+14 <---- PUSHES THE WRONG ADDRESS
jsr _printf
add.w #4,sp
; printf("That was a test\n");
pea .1+15
jsr _printf
add.w #4,sp
;}
.4
movem.l (sp)+,.3
unlk a5
rts
.2 equ 0
.3 reg
.1
dc.b 84,104,105,115,32,105,115,32,97,32,116,101,115,116,0
dc.b 84,104,97,116,32,119,97,115,32,97,32,116,101,115,116
dc.b 10,0
ds 0
;
public _printf
public .begin
dseg
end
-Rico
karl@sugar.UUCP (Karl Lehenbauer) (05/01/88)
I don't know about others, but I don't mind seeing these reports of compiler bugs posted here. I ask, though, that everyone reporting Aztec compiler bugs also forward them to Jim Goodnow at well!manx. There was a posting from him a few months ago in which he indicated that he doesn't get a chance to read the usenet groups regularly but he does maintain that net address for mail and such, so be sure and report bugs you find directly to him as well so they'll get fixed. -k -- "I think Michael is like litmus paper - He's always trying to learn" - Liz Taylor ..!{bellcore!tness1,uunet!nuchat}!sugar!karl, Unix BBS (713) 438-5018