Add implementation of sel_registerTypedName_np() to ObjectiveC2 (libobjc2 nonportable function for registering / getting typed selectors).

git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@31266 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
David Chisnall 2010-09-09 15:17:40 +00:00
parent 7a80adeb9b
commit db04df357a
2 changed files with 28 additions and 0 deletions

View file

@ -1317,3 +1317,29 @@ sel_registerName(const char *selName)
return 0;
return sel_register_name(selName);
}
SEL sel_registerTypedName_np(const char *selName, const char *types)
{
SEL s;
if (types == 0)
{
s = sel_get_any_typed_uid(name);
}
else
{
s = sel_get_typed_uid(name, types);
}
if (s == 0)
{
if (types == 0)
{
s = sel_register_name(name);
}
else
{
s = sel_register_typed_name(name, types);
}
}
return s;
}

View file

@ -299,4 +299,6 @@ BOOL sel_isEqual(SEL sel1, SEL sel2);
SEL sel_registerName(const char *selName);
SEL sel_registerTypedName_np(const char *selName, const char *types);
#endif // __OBJECTIVEC2_RUNTIME_H_INCLUDED