about summary refs log tree commit diff
path: root/src/test/compile-fail/lint-uppercase-variables.rs
diff options
context:
space:
mode:
authorPalmer Cox <p@lmercox.com>2014-02-16 01:03:07 -0500
committerPalmer Cox <p@lmercox.com>2014-03-05 00:22:19 -0500
commit258dbd09ba4aa868b373df7e82721ba0c40167ba (patch)
treecfc189d1cbe1ecb157cd60357bb473cfad3035be /src/test/compile-fail/lint-uppercase-variables.rs
parente3723dc4f1f256e5a454cafb62fd892d85767750 (diff)
downloadrust-258dbd09ba4aa868b373df7e82721ba0c40167ba.tar.gz
rust-258dbd09ba4aa868b373df7e82721ba0c40167ba.zip
Emit the uppercase variable lint for struct fields that have names with uppercase characters
Diffstat (limited to 'src/test/compile-fail/lint-uppercase-variables.rs')
-rw-r--r--src/test/compile-fail/lint-uppercase-variables.rs6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/test/compile-fail/lint-uppercase-variables.rs b/src/test/compile-fail/lint-uppercase-variables.rs
index a9e9fdbbfc9..114d5d4fdf0 100644
--- a/src/test/compile-fail/lint-uppercase-variables.rs
+++ b/src/test/compile-fail/lint-uppercase-variables.rs
@@ -13,6 +13,10 @@
 use std::io::File;
 use std::io::IoError;
 
+struct Something {
+    X: uint //~ ERROR structure field names should start with a lowercase character
+}
+
 fn test(Xx: uint) { //~ ERROR variable names should start with a lowercase character
     println!("{}", Xx);
 }
@@ -30,5 +34,7 @@ fn main() {
     }
 
     test(1);
+
+    let _ = Something { X: 0 };
 }