Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.
Sign upCannot use ty followed by `>>` on macro #25274
Comments
thelink2012
referenced this issue
May 10, 2015
Closed
Cannot expand ty into a generic function constraint during macro expansion #25236
steveklabnik
added
A-grammar
A-macros
labels
May 10, 2015
This comment has been minimized.
This comment has been minimized.
|
Triage: no change |
This comment has been minimized.
This comment has been minimized.
|
This might be fixed now |
This comment has been minimized.
This comment has been minimized.
|
This is still a bug -- I believe the issue is that the follow set checker does not allow |
keeperofdakeys
referenced this issue
Dec 15, 2016
Closed
macros are very whitespace-sensitive when defining functions with type parameters #102
This comment has been minimized.
This comment has been minimized.
|
@jseyfried: I guess you meant I'm not sure what the procedure is for adding tokens to FOLLOW sets. Should we go through the RFC process or just assume that it's a bug in the current design and just make a PR for it? |
This comment has been minimized.
This comment has been minimized.
Yeah, edited.
I think we should assume it is a bug and make a PR to fix. Adding a comment on the RFC PR or tracking issue would probably be a good idea, but I don't think we need to go through the RFC process. |
thelink2012 commentedMay 10, 2015
Using
tyfollowed by>>doesn't work in a macro but it does works when followed by> >instead. This seems very like one of the old C++03 template issues.Using
>>: http://is.gd/KTICULGives
Using
> >instead of>>fixes it: http://is.gd/gSD3MRMeta
All the tests were conducted on the playpen using the nightly and beta option (no difference) so I'm not sure about the version but the issue also happens on my local installation
rustc 1.0.0-beta.3 (5241bf9c3 2015-04-25) (built 2015-04-25)(yep a bit outdated but cba to update eh).