@@ -213,10 +213,10 @@ sub edbgEmitHeader( byval filename as zstring ptr )
213213
214214 ctx.typecnt = 1
215215 ctx.label = NULL
216- ctx.incfile = NULL
217-
218- '' ctx.filename is never used
219- ctx.filename = *filename
216+ ctx.incfile = NULL
217+
218+ '' ctx.filename is never used
219+ ctx.filename = *filename
220220
221221 '' emit source file name
222222 lname = *symbUniqueLabel( )
@@ -267,13 +267,13 @@ sub edbgLineBegin _
267267 ( _
268268 byval proc as FBSYMBOL ptr, _
269269 byval lnum as integer , _
270- byval pos_ as integer , _
271- ByVal filename As zstring ptr _
270+ byval pos_ as integer , _
271+ ByVal filename As zstring ptr _
272272 )
273273
274274 if ( env.clopt.debuginfo = FALSE ) then
275275 exit sub
276- end if
276+ end if
277277
278278 if ( ctx.lnum > 0 ) then
279279 ctx.pos = pos_ - ctx.pos
@@ -283,8 +283,8 @@ sub edbgLineBegin _
283283 end if
284284 end if
285285
286- edbgInclude( filename )
287-
286+ edbgInclude( filename )
287+
288288 ctx.pos = pos_
289289 ctx.lnum = lnum
290290 if ( ctx.isnewline ) then
@@ -534,7 +534,7 @@ sub edbgEmitProcHeader _
534534
535535 ''
536536 ctx.isnewline = TRUE
537- ctx.lnum = 0
537+ ctx.lnum = 0
538538 ctx.pos = 0
539539 ctx.label = NULL
540540
@@ -649,7 +649,7 @@ sub edbgEmitProcFooter _
649649
650650 ''
651651 ctx.isnewline = TRUE
652- ctx.lnum = 0
652+ ctx.lnum = 0
653653 ctx.pos = 0
654654 ctx.label = NULL
655655
@@ -1018,32 +1018,32 @@ end sub
10181018
10191019sub edbgInclude( byval incfile as zstring ptr )
10201020 dim as string lname
1021-
1022- '' NOTE: originally, fbc used STAB_TYPE_BINCL and STAB_TYPE_EINCL
1023- '' to mark the beginning and end of an include file. The purpose
1024- '' for these markers is so the linker (LD) can remove duplicate
1025- '' debug type information from the final EXE. However, because
1026- '' fbc only emits types actually used, the end result is that
1027- '' type information from a header (.BI) is often different from
1028- '' one object module to another is generally not used in the
1029- '' way that BINCL/EINCL/EXCL was intented.
1030-
1031- '' incfile is the new include file or main file name
1032-
1033- '' coming from _close incfile is null so no real need to change
1034- If ( incfile = NULL ) Then
1035- Exit Sub
1036- EndIf
1037-
1038- '' Already handling the correct name
1039- if ( incfile = ctx.incfile ) Then
1040- exit sub
1041- end If
1042-
1043- emitSECTION( IR_SECTION_CODE, 0 )
1044- lname = *symbUniqueLabel( )
1045- hEmitSTABS( STAB_TYPE_SOL, incfile, 0 , 0 , lname )
1046- hLABEL( lname )
1047-
1048- ctx.incfile = incfile
1021+
1022+ '' NOTE: originally, fbc used STAB_TYPE_BINCL and STAB_TYPE_EINCL
1023+ '' to mark the beginning and end of an include file. The purpose
1024+ '' for these markers is so the linker (LD) can remove duplicate
1025+ '' debug type information from the final EXE. However, because
1026+ '' fbc only emits types actually used, the end result is that
1027+ '' type information from a header (.BI) is often different from
1028+ '' one object module to another is generally not used in the
1029+ '' way that BINCL/EINCL/EXCL was intented.
1030+
1031+ '' incfile is the new include file or main file name
1032+
1033+ '' coming from _close incfile is null so no real need to change
1034+ If ( incfile = NULL ) Then
1035+ Exit Sub
1036+ EndIf
1037+
1038+ '' Already handling the correct name
1039+ if ( incfile = ctx.incfile ) Then
1040+ exit sub
1041+ end If
1042+
1043+ emitSECTION( IR_SECTION_CODE, 0 )
1044+ lname = *symbUniqueLabel( )
1045+ hEmitSTABS( STAB_TYPE_SOL, incfile, 0 , 0 , lname )
1046+ hLABEL( lname )
1047+
1048+ ctx.incfile = incfile
10491049end sub
0 commit comments