[Issue 9065] Please consider adding these std.traits
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Tue Nov 27 07:19:05 PST 2012
http://d.puremagic.com/issues/show_bug.cgi?id=9065
--- Comment #37 from Kenji Hara <k.hara.pg at gmail.com> 2012-11-27 07:19:03 PST ---
(In reply to comment #31)
> (In reply to comment #20)
> > https://gist.github.com/4152297
>
> I am seeing a few error cases:
>
> enum j { k = 10 }
>
> pragma(msg, isFunction!(j.k));
> pragma(msg, isManifestConstant!(j.k));
> pragma(msg, isPropertyFunction!(j.k));
> pragma(msg, isVariable!(j.k));
>
> These all throw errors.
Fixed.
(In reply to comment #34)
> @Kenji:
>
> I'm getting an error when using your new isFunction, here's the case:
>
> struct S
> {
> static string func(alias Class)()
> {
> foreach(m; __traits(allMembers, Class))
> {
> pragma(msg, m);
> static if( isFunction!( mixin( m ) ) )
> bool b = true;
> }
> }
>
> enum nothing = func!(typeof(this))();
> mixin(nothing);
> }
This is a compiler bug, not an issue of isFunction template.
I filed new bug 9083.
--
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