         Edinburgh IMP77 Compiler - Version 8.4
    1
				NO_APP
		.Ltext0:
				.section	.rodata.str1.1,"aMS",@progbits,1
		.LC6:
		 		.string	""
				.section	.rodata
		.LC0:
		 		.byte	21
		 		.string	"test-new/test113b.imp"
		 		.zero	233
				.align	2
				.globl	GETYNX
		GETYNX:
		.LFB185:
    2
    3 %externalintegerfn get YNX
		 		link.w %fp,#-1024
		 		movem.l #16188,-(%sp)
    4   %on %event 9 %start
		 		pea 1.w
		 		pea _imp_event+532
		 		jsr __sigsetjmp
		.LVL0:
		 		addq.l #8,%sp
		 		tst.l %d0
		 		jne .L17
		.LVL1:
		 		pea 512.w
		 		pea _imp_event
		 		jsr _imp_on_event_enter
		.LVL2:
		 		addq.l #8,%sp
		 		tst.l %a0
		 		jeq .L14
		.LBB44:
		.LBB45:
		 		lea _imp_nextsymbol,%a4
		.LBE45:
		.LBE44:
		.LBB47:
		.LBB48:
		 		lea _imp_skipsymbol,%a3
		.LBE48:
		.LBE47:
    5     %result = 'X'
		 		move.w #88,%a2
		.L1:
		 		move.w #88,%a2
		.L4:
		 		jra .L1
		.LFE185:
				.section	.rodata
		.LC7:
		 		.string	"Y or N: "
		 		.zero	6
		.LC2:
		 		.byte	8
		 		.string	"Starting"
		 		.zero	246
		.LC4:
		 		.byte	3
		 		.string	"No?"
		 		.zero	251
		.LC1:
		 		.byte	12
		 		.string	"What indeed?"
		 		.zero	242
		.LC3:
		 		.byte	4
		 		.string	"Yes!"
		 		.zero	250
		.LC5:
		 		.byte	39
		 		.string	"\nExiting on trapped END OF FILE event!."
		 		.zero	215
				.align	2
				.globl	main
		main:
		.LFB186:
    6   %finish
    7   %integer c
    8   %cycle
    9     !read symbol(c)  ;! read symbol currently not working due to %name parameters not being handled yet.
   10     c = next symbol; skip symbol
   11     %signal 7,1,0 %if c = '?'
		 		moveq #63,%d0
		 		cmp.l %a2,%d0
		 		jeq .L18
		.L8:
		.LVL18:
		.LBB54:
		 		lea (-97,%a2),%a0
		 		moveq #25,%d0
		 		cmp.l %a0,%d0
		 		jcs .L12
		.LBE54:
   12     c = c - 'a' + 'A' %if 'a' <= c <= 'z'
		 		move.l %fp,%d4
		 		add.l #-512,%d4
		 		move.l %fp,%d3
		 		add.l #-256,%d3
		.LBB50:
		 		move.l %fp,%d6
		 		add.l #-1024,%d6
		 		move.l %fp,%d5
		 		add.l #-768,%d5
		 		jra .L5
		.LVL3:
		.L17:
		.LBE50:
		 		pea .LC6
		 		move.l %d4,%a1
		 		jsr _imp_c2istr
		.LVL5:
		 		addq.l #4,%sp
		 		move.l _imp_current_line,%d2
		 		jne .L9
		 		moveq #12,%d2
		.L9:
		 		move.l _imp_current_file,%d0
		 		jeq .L10
		 		move.l %d0,-(%sp)
		 		move.l %d3,%a1
		 		jsr _imp_c2istr
		.LVL6:
		 		addq.l #4,%sp
		.L11:
		 		clr.l -(%sp)
		 		pea 1.w
		 		pea 7.w
		 		lea (-256,%sp),%sp
		 		move.l %sp,%d0
		 		move.l #256,%d7
		 		move.l %d7,-(%sp)
		 		move.l %d4,-(%sp)
		 		move.l %d0,-(%sp)
		 		lea memcpy,%a5
		 		jsr (%a5)
		.LVL7:
		 		lea (12,%sp),%sp
		 		move.l %d2,-(%sp)
		 		lea (-256,%sp),%sp
		 		move.l %sp,%d0
		 		move.l %d7,-(%sp)
		 		move.l %d3,-(%sp)
		 		move.l %d0,-(%sp)
		 		jsr (%a5)
		.LVL8:
		 		lea (12,%sp),%sp
		 		jsr _signal_event
		.LVL9:
		 		lea (528,%sp),%sp
		 		jra .L8
		.L10:
		.LBB51:
		 		move.l #256,%d7
		 		move.l %d7,-(%sp)
		 		pea .LC0
		 		move.l %d6,-(%sp)
		 		lea memcpy,%a5
		 		jsr (%a5)
		.LVL10:
		 		move.l %d7,-(%sp)
		 		move.l %d6,-(%sp)
		 		move.l %d5,-(%sp)
		 		jsr (%a5)
		.LVL11:
		.LBE51:
		 		move.l %d7,-(%sp)
		 		move.l %d5,-(%sp)
		 		move.l %d3,-(%sp)
		 		jsr (%a5)
		.LVL12:
		 		lea (36,%sp),%sp
		 		jra .L11
		.LVL13:
		.L12:
   13     %result = c %if c = 'Y' %or c = 'N'
		 		moveq #89,%d0
		 		cmp.l %a2,%d0
		 		jeq .L1
   14   %repeat
		 		moveq #78,%d0
		 		cmp.l %a2,%d0
		 		jeq .L1
		.LVL14:
		.L5:
		.L6:
		.L7:
		.LBB52:
		.LBB46:
		 		jsr (%a4)
		.LVL15:
		 		move.l %d0,%a2
		.LVL16:
		.LBE46:
		.LBE52:
		.LBB53:
		.LBB49:
		 		jsr (%a3)
		.LVL17:
		.LBE49:
		.LBE53:
   15 %end
		 		move.l %a2,%d0
		 		movem.l -1064(%fp),#15612
		 		unlk %fp
		 		rts
		.LVL4:
		.L18:
   16
   17 ! A complete program.  Should run.
   18 %begin
		.LVL21:
		 		link.w %fp,#-3328
		 		movem.l #15408,-(%sp)
		 		move.l 12(%fp),-(%sp)
		 		move.l 8(%fp),-(%sp)
		 		jsr _imp_initialise
		.LVL22:
		 		addq.l #8,%sp
   19   %integer Answer
		 		lea (-32,%a2),%a2
		.LVL19:
		 		jra .L12
		.LVL20:
		.L14:
   20   %on %event 7 %start
		 		pea 1.w
		 		pea _imp_event+532
		 		jsr __sigsetjmp
		.LVL23:
		 		addq.l #8,%sp
		 		tst.l %d0
		 		jne .L21
		.LVL24:
		 		pea 128.w
		 		pea _imp_event
		 		jsr _imp_on_event_enter
		.LVL25:
		 		addq.l #8,%sp
		 		tst.l %a0
		 		jeq .L21
		.LVL26:
		.L22:
		.LBB55:
   21     print string("What indeed?"); newline
		 		move.l %fp,%d3
		.LVL54:
		 		add.l #-2048,%d3
		.LVL55:
		 		move.l #256,%d2
		 		move.l %d2,-(%sp)
		 		pea .LC1
		 		move.l %d3,-(%sp)
		 		lea memcpy,%a2
		 		jsr (%a2)
		.LVL56:
		 		move.l %fp,%d4
		.LVL57:
		 		add.l #-3328,%d4
		.LVL58:
		 		move.l %d2,-(%sp)
		 		move.l %d3,-(%sp)
		 		move.l %d4,-(%sp)
		 		jsr (%a2)
		.LVL59:
		 		add.l #512,%d3
		 		move.l %d2,-(%sp)
		 		move.l %d4,-(%sp)
		 		move.l %d3,-(%sp)
		 		jsr (%a2)
		.LVL60:
		.LBE68:
		.LBB69:
		.LBB70:
		 		lea (-220,%sp),%sp
		 		move.l %sp,%d0
		 		move.l %d2,-(%sp)
		 		move.l %d3,-(%sp)
		 		move.l %d0,-(%sp)
		 		jsr (%a2)
		.LVL61:
		 		lea (12,%sp),%sp
		 		jsr _imp_printstring
		.LVL62:
		 		add.l %d2,%sp
		.LBE70:
		.LBE69:
		.LBB71:
		.LBB72:
		 		jsr _imp_newline
		.LVL63:
		 		jra .L22
		.LVL64:
		.L28:
		.LBE72:
		.LBE71:
		.LBB73:
   22     ! drop through and restart...
   23   %finish
   24
   25   prompt("Y or N: ");
		 		pea 240.w
		 		clr.l -(%sp)
		 		pea -2032(%fp)
		 		jsr memset
		.LVL27:
		 		pea 9.w
		 		pea .LC7
		 		pea -2047(%fp)
		 		lea memcpy,%a2
		 		jsr (%a2)
		.LVL28:
		 		clr.l -2038(%fp)
		 		clr.w -2034(%fp)
		 		move.b #8,-2048(%fp)
		 		move.l %fp,%d5
		.LVL29:
		 		add.l #-3072,%d5
		.LVL30:
		 		move.l %fp,%d3
		.LVL31:
		 		add.l #-2048,%d3
		.LVL32:
		 		move.l #256,%d2
		 		move.l %d2,-(%sp)
		 		move.l %d3,-(%sp)
		 		move.l %d5,-(%sp)
		 		jsr (%a2)
		.LVL33:
		 		move.b #8,-3072(%fp)
		 		move.l %fp,%d4
		.LVL34:
		 		add.l #-1280,%d4
		.LVL35:
		 		lea (36,%sp),%sp
		 		move.l %d2,-(%sp)
		 		move.l %d5,-(%sp)
		 		move.l %d4,-(%sp)
		 		jsr (%a2)
		.LVL36:
		.LBE55:
		.LBB56:
		.LBB57:
		 		pea __PRETTY_FUNCTION__.5501
		 		jsr check_instream
		.LVL37:
		 		lea (16,%sp),%sp
		 		move.b #8,-1280(%fp)
		 		move.l %d2,-(%sp)
		 		move.l %d4,-(%sp)
		 		pea _imp_promptstr
		 		jsr (%a2)
		.LVL38:
		.LBE57:
		.LBE56:
		.LBB58:
   26   print string("Starting"); newline
		 		move.l %d2,-(%sp)
		 		pea .LC2
		 		move.l %d3,-(%sp)
		 		jsr (%a2)
		.LVL39:
		 		add.l #-1536,%d4
		.LVL40:
		 		move.l %d2,-(%sp)
		 		move.l %d3,-(%sp)
		 		move.l %d4,-(%sp)
		 		jsr (%a2)
		.LVL41:
		 		add.l #1024,%d3
		 		lea (36,%sp),%sp
		 		move.l %d2,-(%sp)
		 		move.l %d4,-(%sp)
		 		move.l %d3,-(%sp)
		 		jsr (%a2)
		.LVL42:
		.LBE58:
		.LBB59:
		.LBB60:
		 		lea (-256,%sp),%sp
		 		move.l %sp,%d0
		 		move.l %d2,-(%sp)
		 		move.l %d3,-(%sp)
		 		move.l %d0,-(%sp)
		 		jsr (%a2)
		.LVL43:
		 		lea (12,%sp),%sp
		 		jsr _imp_printstring
		.LVL44:
		 		lea (268,%sp),%sp
		.LBE60:
		.LBE59:
		.LBB61:
		.LBB62:
		 		jsr _imp_newline
		.LVL45:
		.LBE62:
		.LBE61:
   27   %cycle
   28     Answer = get YNX
		 		lea GETYNX,%a3
		.L23:
		 		jsr (%a3)
		.LVL46:
   29     %if Answer = 'Y' %start
		 		moveq #89,%d1
		 		cmp.l %d0,%d1
		 		jeq .L28
		.L24:
   30       print string("Yes!"); newline
		 		move.l #256,%d2
		 		move.l %d2,-(%sp)
		 		pea .LC3
		 		pea -2048(%fp)
		 		lea memcpy,%a2
		 		jsr (%a2)
		.LVL65:
		 		move.l %d2,-(%sp)
		 		pea -2048(%fp)
		 		pea -2560(%fp)
		 		jsr (%a2)
		.LVL66:
		 		move.l %d2,-(%sp)
		 		pea -2560(%fp)
		 		pea -768(%fp)
		 		jsr (%a2)
		.LVL67:
		.LBE73:
		.LBB74:
		.LBB75:
		 		lea (-220,%sp),%sp
		 		move.l %sp,%d0
		 		move.l %d2,-(%sp)
		 		pea -768(%fp)
		 		move.l %d0,-(%sp)
		 		jsr (%a2)
		.LVL68:
		 		lea (12,%sp),%sp
		 		jsr _imp_printstring
		.LVL69:
		 		add.l %d2,%sp
		.LBE75:
		.LBE74:
		.LBB76:
		.LBB77:
		 		jsr _imp_newline
		.LVL70:
		 		jra .L23
		.LVL71:
		.L26:
		.LBE77:
		.LBE76:
   31     %finish %else %if Answer = 'N' %start
   32       print string("No?"); newline
		 		move.l #256,%d2
		 		move.l %d2,-(%sp)
		 		pea .LC4
		 		pea -2048(%fp)
		 		lea memcpy,%a2
		 		jsr (%a2)
		.LVL47:
		 		move.l %d2,-(%sp)
		 		pea -2048(%fp)
		 		pea -2304(%fp)
		 		jsr (%a2)
		.LVL48:
		 		move.l %d2,-(%sp)
		 		pea -2304(%fp)
		 		pea -512(%fp)
		 		jsr (%a2)
		.LVL49:
		.LBE63:
		.LBB64:
		.LBB65:
		 		lea (-220,%sp),%sp
		 		move.l %sp,%d0
		 		move.l %d2,-(%sp)
		 		pea -512(%fp)
		 		move.l %d0,-(%sp)
		 		jsr (%a2)
		.LVL50:
		 		lea (12,%sp),%sp
		 		jsr _imp_printstring
		.LVL51:
		 		add.l %d2,%sp
		.LBE65:
		.LBE64:
		.LBB66:
		.LBB67:
		 		jsr _imp_newline
		.LVL52:
		 		jra .L23
		.LVL53:
		.L21:
		.LBE67:
		.LBE66:
		.LBB68:
   33     %finish %else %if Answer = 'X' %start
		 		moveq #78,%d1
		 		cmp.l %d0,%d1
		 		jne .L26
		.LBB63:
   34       print string("
		 		move.l %fp,%d3
		.LVL74:
		 		add.l #-2048,%d3
		.LVL75:
		 		move.l #256,%d2
		 		move.l %d2,-(%sp)
		 		pea .LC5
		 		move.l %d3,-(%sp)
		 		lea memcpy,%a2
		 		jsr (%a2)
		.LVL76:
		 		move.l %fp,%d4
		.LVL77:
		 		add.l #-1792,%d4
		.LVL78:
		 		move.l %d2,-(%sp)
		 		move.l %d3,-(%sp)
		 		move.l %d4,-(%sp)
		 		jsr (%a2)
		.LVL79:
		 		add.l #1792,%d3
		 		move.l %d2,-(%sp)
		 		move.l %d4,-(%sp)
		 		move.l %d3,-(%sp)
		 		jsr (%a2)
		.LVL80:
		.LBE80:
		.LBB81:
		.LBB82:
		 		lea (-220,%sp),%sp
		 		move.l %sp,%d0
		 		move.l %d2,-(%sp)
		 		move.l %d3,-(%sp)
		 		move.l %d0,-(%sp)
		 		jsr (%a2)
		.LVL81:
		 		lea (12,%sp),%sp
		 		jsr _imp_printstring
		.LVL82:
		 		add.l %d2,%sp
		.LVL83:
		.LBE82:
		.LBE81:
		.LBB83:
		.LBB84:
		 		pea 2.w
		 		jsr _imp_newlines
		.LVL84:
		.LBE84:
		.LBE83:
		.LBB85:
		.LBB86:
		 		clr.l (%sp)
		 		jsr exit
		.LVL85:
		.LBE86:
		.LBE85:
		.LFE186:
				.section	.rodata
		__PRETTY_FUNCTION__.5501:
		 		.string	"_imp_PROMPT"
		.Letext0:
   35 Exiting on trapped END OF FILE event!."); newlines(2)
		 		moveq #88,%d1
		 		cmp.l %d0,%d1
		 		jeq .L29
		.L27:
		.LVL72:
		.LBB78:
		.LBB79:
		 		clr.l -(%sp)
		 		jsr exit
		.LVL73:
		.L29:
		.LBE79:
		.LBE78:
		.LBB80:
   36       %stop
   37     %finish %else %start
   38       %monitor %and %stop
   39     %finish
   40   %repeat
   41 %endofprogram
   39 Statements compiled
