Skip to content
This repository was archived by the owner on Aug 9, 2025. It is now read-only.

Commit b41e68a

Browse files
committed
Merge pull request #148 from Dmitry-Me/getRidOfUnneededDynamic
Get rid of unneeded dynamic
2 parents 58bb151 + 42f37e4 commit b41e68a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

CPPCheckPlugin/CPPCheckPluginPackage.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -377,7 +377,7 @@ private static bool isCppFile(dynamic file)
377377
// Using Reflection to get to the interface and access the property directly instead.
378378
Type fileObjectType = file.GetType();
379379
var vcFileInterface = fileObjectType.GetInterface("Microsoft.VisualStudio.VCProjectEngine.VCFile");
380-
var fileTypeValue = vcFileInterface.GetProperty("FileType").GetValue(file);
380+
var fileTypeValue = vcFileInterface.GetProperty("FileType").GetValue((object)file);
381381
Type fileTypeEnumType = fileTypeValue.GetType();
382382
Debug.Assert(fileTypeEnumType.FullName == "Microsoft.VisualStudio.VCProjectEngine.eFileType");
383383
var fileTypeEnumValue = Enum.GetName(fileTypeEnumType, fileTypeValue);

0 commit comments

Comments
 (0)