This website requires JavaScript.
Explore
Help
Sign In
nordic-dev.net
/
rust
Watch
2
Star
0
Fork
0
You've already forked rust
mirror of
https://github.com/rust-lang/rust.git
synced
2025-02-12 06:53:05 +00:00
Code
Issues
Packages
Projects
Releases
Wiki
Activity
b335ec9ec8
rust
/
tests
/
ui
/
macros
/
semi-after-macro-ty.rs
9 lines
98 B
Rust
Raw
Normal View
History
Unescape
Escape
[AUTO-GENERATED] Migrate ui tests from `//` to `//@` directives
2024-02-16 20:02:50 +00:00
//@ run-pass
syntax: Allow semi tokens after macro ty/path This commit expands the follow set of the `ty` and `path` macro fragments to include the semicolon token as well. A semicolon is already allowed after these tokens, so it's currently a little too restrictive to not have a semicolon allowed. For example: extern { fn foo() -> i32; // semicolon after type } fn main() { struct Foo; Foo; // semicolon after path }
2015-07-12 22:53:04 +00:00
macro_rules
!
foo
{
(
$t
:
ty
;
$p
:
path
;
)
=
>
{
}
}
fn
main
(
)
{
foo!
(
i32
;
i32
;
)
;
}
Reference in New Issue
Copy Permalink