[0.3.x] fixed: name of function pointers

[0.3.x] fixed: name of function arrays
[0.3.x] added: kdlib test for function names

git-svn-id: https://pykd.svn.codeplex.com/svn@88793 9b283d60-5439-405e-af05-b73fd8c4d996
This commit is contained in:
SND\EreTIk_cp 2014-07-03 11:55:22 +00:00 committed by Mikhail I. Izmestev
parent 3d75560b17
commit 7e854ab519

View File

@ -289,12 +289,12 @@ class TypeInfoTest( unittest.TestCase ):
funcptrtype = target.module.typedVar( "CdeclFuncPtr" ).type() funcptrtype = target.module.typedVar( "CdeclFuncPtr" ).type()
self.assertEqual(funcptrtype.name(), "Void(__cdecl*)(Int4B, Float)") self.assertEqual(funcptrtype.name(), "Void(__cdecl*)(Int4B, Float)")
functype = target.module.typedVar( "MethodPtr" ).type().deref() functype = target.module.typedVar( "MethodPtr" ).type()
self.assertEqual(functype.name(), "Void(__thiscall FuncTestClass::*)()") self.assertEqual(functype.name(), "Void(__thiscall FuncTestClass::*)()")
def testFunctionArrName(self): def testFunctionArrName(self):
funcptrtype = target.module.typedVar( "ArrayOfCdeclFuncPtr" ).type() funcptrtype = target.module.typedVar( "ArrayOfCdeclFuncPtr" ).type()
self.assertEqual(funcptrtype.name(), "Void(__cdecl*[3])(Int4B, Float)") self.assertEqual(funcptrtype.name(), "Void(__cdecl*[3])(Int4B, Float)")
functype = target.module.typedVar( "ArrayOfMethodPtr" ).type().deref() functype = target.module.typedVar( "ArrayOfMethodPtr" ).type()
self.assertEqual(functype.name(), "Void(__thiscall FuncTestClass::*[2])()") self.assertEqual(functype.name(), "Void(__thiscall FuncTestClass::*[2])()")