Description
My limited understanding is that TokenStreams
inputs and outputs for proc-macros have to abide to some minimal level of syntax (e.x. can't have mismatched delimiters outside of string literals), but everything else should be fair game for the proc-macro to handle (please edit the title if there is a better term for what I am describing). However, I found a case where the proc-macro system will forcibly error just because Rust doesn't support it, and it doesn't involve any special delimiters.
I am adding hexadecimal, binary, etc floating point support to my awint crate and encountered this problem:
proc_macro_ex!(0x123.456_i256f128); // error: hexadecimal float literal is not supported
this is frustrating because it works if I chose some other closely related convention like 0j123.456_i256f128
.
I am titling this issue more generally because I want to make sure there are not other cases like it.