if any typedef in the chain has a pointer-c-type, use it
parent
3d97bd2ae0
commit
75e2a5098e
|
@ -44,6 +44,14 @@ TYPEDEF: char MyFunkyChar
|
|||
[ f ] [ pointer: char c-type pointer: MyFunkyChar c-type = ] unit-test
|
||||
[ { char* ascii } ] [ pointer: MyFunkyChar c-type ] unit-test
|
||||
|
||||
TYPEDEF: MyFunkyChar MyFunkyTypedef
|
||||
|
||||
[ { char* ascii } ] [ pointer: MyFunkyTypedef c-type ] unit-test
|
||||
|
||||
TYPEDEF: MyFunkyChar* MyFunkyString
|
||||
|
||||
[ { char* ascii } ] [ MyFunkyString c-type ] unit-test
|
||||
|
||||
TYPEDEF: char* MyString
|
||||
|
||||
[ t ] [ char* c-type MyString c-type = ] unit-test
|
||||
|
|
|
@ -301,7 +301,7 @@ CONSTANT: primitive-types
|
|||
: special-pointer-type ( type -- special-type )
|
||||
dup c-type-word? [
|
||||
dup "pointer-c-type" word-prop
|
||||
[ ] [ resolve-pointer-typedef "pointer-c-type" word-prop ] ?if
|
||||
[ ] [ "c-type" word-prop special-pointer-type ] ?if
|
||||
] [ drop f ] if ;
|
||||
|
||||
: primitive-pointer-type? ( type -- ? )
|
||||
|
|
Loading…
Reference in New Issue