Using include_str
in an attribute
#54775
Labels
C-feature-request
Category: A feature request, i.e: not implemented / a PR.
T-lang
Relevant to the language team, which will review and decide on the PR/issue.
Not sure if this should be an RFC or a bug/issue, but I'm trying to add an attribute to a struct where the value of the attribute is a
&'static str
. It would be nice to have the contents of the string in a separate file so I can have syntax highlighting when editing that file, and then have that be pulled in to the rust module and built. The following should reproduce the issue:Cargo.toml
:And then in a module, try to compile the following. The
src
attribute takes a string as its value, that contains the source code of the shader to compile.When I compile, I get the following output:
The text was updated successfully, but these errors were encountered: