[Issue 4265] It should be possible to query template parameters with __traits

d-bugmail at puremagic.com d-bugmail at puremagic.com
Sat Dec 22 15:24:33 PST 2012


http://d.puremagic.com/issues/show_bug.cgi?id=4265



--- Comment #6 from Andrej Mitrovic <andrej.mitrovich at gmail.com> 2012-12-22 15:24:32 PST ---
(In reply to comment #5)
> I can have a pull ready soon for 2 traits:
> 
> 1. Get the template out of the template instance (Foo!int => Foo)
> 2. Get the arguments used to instantiate the template (Foo!int => (int))
> 
> However I need some good names for these. I thought about using
> '__traits(getTemplateArgs, T)' and '__traits(getTemplateParent, T)', any better
> suggestions?

nazriel suggested:
'getTemplateName'
'getTemplateArgs' 

I think it's better because they line up nicely.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------


More information about the Digitalmars-d-bugs mailing list