Skip to content

Commit d69a762

Browse files
committed
Remove useless targetFilePath variable
1 parent 912c5a4 commit d69a762

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

internal/arduino/builder/internal/detector/detector.go

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -293,7 +293,6 @@ func (l *SketchLibrariesDetector) findMissingIncludesInCompilationUnit(
293293
) error {
294294
sourceFile := sourceFileQueue.Pop()
295295
sourcePath := sourceFile.SourcePath()
296-
targetFilePath := paths.NullPath()
297296
depPath := sourceFile.DepfilePath()
298297
objPath := sourceFile.ObjectPath()
299298

@@ -338,7 +337,7 @@ func (l *SketchLibrariesDetector) findMissingIncludesInCompilationUnit(
338337
}
339338
first = false
340339
} else {
341-
preprocResult, preprocErr = preprocessor.GCC(ctx, sourcePath, targetFilePath, includeFolders, buildProperties)
340+
preprocResult, preprocErr = preprocessor.GCC(ctx, sourcePath, paths.NullPath(), includeFolders, buildProperties)
342341
if l.logger.Verbose() {
343342
l.logger.WriteStdout(preprocResult.Stdout)
344343
}
@@ -371,7 +370,7 @@ func (l *SketchLibrariesDetector) findMissingIncludesInCompilationUnit(
371370

372371
// If preprocess result came from cache, run the preprocessor to obtain the actual error to show
373372
if preprocErr == nil || len(preprocResult.Stderr) == 0 {
374-
preprocResult, preprocErr = preprocessor.GCC(ctx, sourcePath, targetFilePath, includeFolders, buildProperties)
373+
preprocResult, preprocErr = preprocessor.GCC(ctx, sourcePath, paths.NullPath(), includeFolders, buildProperties)
375374
if l.logger.Verbose() {
376375
l.logger.WriteStdout(preprocResult.Stdout)
377376
}

0 commit comments

Comments
 (0)