@@ -214,7 +214,11 @@ sub edbgEmitHeader( byval filename as zstring ptr )
214214 ctx.typecnt = 1
215215 ctx.label = NULL
216216 ctx.incfile = NULL
217- ctx.filename = *filename
217+ # If defined( __FB_WIN32__ ) or defined( __FB_DOS__ )
218+ ctx.filename = UCase(*filename)
219+ # Else
220+ ctx.filename = *filename
221+ # EndIf
218222
219223 '' emit source file name
220224 lname = *symbUniqueLabel( )
@@ -240,7 +244,6 @@ sub edbgEmitHeader( byval filename as zstring ptr )
240244
241245 emitWriteStr( "" )
242246
243- hEmitSTABS( STAB_TYPE_BINCL, filename, 0 , 0 )
244247end sub
245248
246249'':::::
@@ -1018,40 +1021,22 @@ end sub
10181021sub edbgInclude( byval incfile as zstring ptr )
10191022 dim as string lname
10201023
1021- '' incfile is the new include file for which we should open a block.
1022- '' incfile can be NULL to indicate that no next include file is coming,
1023- '' in which case we just want to return to the toplevel .bas file name,
1024- '' if we previously opened an include file block.
1024+ '' incfile is the new include file or main file name
10251025
1026- '' Already in the correct block?
1027- '' (same include file, or NULL for toplevel)
1028- if ( incfile = ctx.incfile ) then
1029- exit sub
1030- end if
1031-
1032- '' Currently in an include file block?
1033- if ( ctx.incfile ) then
1034- '' Close it
1035- hEmitSTABS( STAB_TYPE_EINCL, "" , 0 , 0 )
1036-
1037- '' "Return" to the main filename, if no new include file block
1038- '' will be opened
1039- if ( incfile = NULL ) then
1040- emitSECTION( IR_SECTION_CODE, 0 )
1041- lname = *symbUniqueLabel( )
1042- hEmitSTABS( STAB_TYPE_SOL, ctx.filename, 0 , 0 , lname )
1043- hLABEL( lname )
1044- end if
1045- end if
1026+ '' coming from _close incfile is null so no real need to change
1027+ If ( incfile = NULL ) Then
1028+ Exit Sub
1029+ EndIf
10461030
1047- ctx.incfile = incfile
1031+ '' Already handling the correct name
1032+ if ( incfile = ctx.incfile ) Then
1033+ exit sub
1034+ end If
1035+
1036+ emitSECTION( IR_SECTION_CODE, 0 )
1037+ lname = *symbUniqueLabel( )
1038+ hEmitSTABS( STAB_TYPE_SOL, incfile, 0 , 0 , lname )
1039+ hLABEL( lname )
10481040
1049- '' Open new include file block if needed
1050- if ( incfile ) then
1051- hEmitSTABS( STAB_TYPE_BINCL, incfile, 0 , 0 )
1052- emitSECTION( IR_SECTION_CODE, 0 )
1053- lname = *symbUniqueLabel( )
1054- hEmitSTABS( STAB_TYPE_SOL, incfile, 0 , 0 , lname )
1055- hLABEL( lname )
1056- end if
1041+ ctx.incfile = incfile
10571042end sub
0 commit comments