-
Notifications
You must be signed in to change notification settings - Fork 13.6k
Closed
Labels
A-attributesArea: Attributes (`#[…]`, `#![…]`)Area: Attributes (`#[…]`, `#![…]`)A-testsuiteArea: The testsuite used to check the correctness of rustcArea: The testsuite used to check the correctness of rustc
Description
use std;
fn main () {
nonTest()
}
fn nonTest() {
anotherTest ()
}
#[test]
fn test () {
nonTest()
}
#[test]
fn anotherTest () {
}
This code obviously doesn't compile without any flags, but it does compile with rustc --test.
From my perspective I cannot see why the parser allows nonTest to call anotherTest. Ever. Except in an example to show that it doesn't work.
Though, this is probably low priority.
Metadata
Metadata
Assignees
Labels
A-attributesArea: Attributes (`#[…]`, `#![…]`)Area: Attributes (`#[…]`, `#![…]`)A-testsuiteArea: The testsuite used to check the correctness of rustcArea: The testsuite used to check the correctness of rustc