Re: Use "sel_getUid" for undeclared selector

Richard Frith-Macdonald <[email protected]>
Newsgroups gmane.comp.lib.gnustep.user
Message-ID <[email protected]>
On 3 Feb 2005, at 13:13, Sébastien Pierre wrote:

> Hi all !
>
> I would like to know if it is possible to do a "sel_getUid" that  
> returns a non-NULL SEL for a selector that is not declared in the code  
> ?
>
> BTW, this question is related to previous mails  
> (<http://lists.gnu.org/archive/html/help-gnustep/2005-02/ 
> msg00014.html> and  
> <http://lists.gnu.org/archive/html/help-gnustep/2005-02/ 
> msg00013.html>).

You can create new selectors with the gnu runtime using  
sel_register_typed_name()
See the gnu runtime source/docs for details.
Basically, this has two C-string arguments - the name of the selector  
and the encoded type information.
If you do not need a typed selector, you can use sel_get_uid() instead.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.