aboutsummaryrefslogtreecommitdiffstats
path: root/src/x11
diff options
context:
space:
mode:
authorNicholas Bishop <nicholasbishop@gmail.com>2015-03-22 18:54:18 -0400
committerNicholas Bishop <nicholasbishop@gmail.com>2015-03-22 18:54:18 -0400
commit3413a2d973f0851686c1dc286b2459afafc7f403 (patch)
tree86444bc456903eb7cdb99feff7adf6425dfa2160 /src/x11
parent3ad95d58679d7b3740eff791de2abe6857598ecd (diff)
downloadglutin-3413a2d973f0851686c1dc286b2459afafc7f403.tar.gz
glutin-3413a2d973f0851686c1dc286b2459afafc7f403.zip
Fix compilation by replacing "range" with ".." syntax
Diffstat (limited to 'src/x11')
-rw-r--r--src/x11/window/mod.rs2
-rw-r--r--src/x11/window/monitor.rs2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/x11/window/mod.rs b/src/x11/window/mod.rs
index 7845d07..385a913 100644
--- a/src/x11/window/mod.rs
+++ b/src/x11/window/mod.rs
@@ -348,7 +348,7 @@ impl Window {
return Err(OsError(format!("Could not query the video modes")));
}
- for i in range(0, mode_num) {
+ for i in 0..mode_num {
let mode: ffi::XF86VidModeModeInfo = ptr::read(*modes.offset(i as isize) as *const _);
if mode.hdisplay == dimensions.0 as u16 && mode.vdisplay == dimensions.1 as u16 {
best_mode = i;
diff --git a/src/x11/window/monitor.rs b/src/x11/window/monitor.rs
index 77ac4ec..1dc0350 100644
--- a/src/x11/window/monitor.rs
+++ b/src/x11/window/monitor.rs
@@ -18,7 +18,7 @@ pub fn get_available_monitors() -> VecDeque<MonitorID> {
};
let mut monitors = VecDeque::new();
- monitors.extend(range(0, nb_monitors).map(|i| MonitorID(i as u32)));
+ monitors.extend((0..nb_monitors).map(|i| MonitorID(i as u32)));
monitors
}