modstruct: Implement 'O', 'P', 's' types for packed structs.

This is required to deal with, well, packed C structs containing pointers.
This commit is contained in:
Paul Sokolovsky 2014-09-06 19:24:52 +03:00
parent 722e562736
commit 78fde4819c
1 changed files with 2 additions and 0 deletions

View File

@ -58,6 +58,8 @@ int mp_binary_get_size(char struct_type, char val_type, mp_uint_t *palign) {
size = 4; break;
case 'q': case 'Q':
size = 8; break;
case 'P': case 'O': case 'S':
size = sizeof(void*); break;
}
break;
case '@': {