Migrate to 2018 edition. (#924)
* Migrate to 2018 edition. * Use impl Iterator at one site. * Fix more rust 2018 idioms.
This commit is contained in:
parent
2e0bbc091f
commit
f879bca21c
71 changed files with 411 additions and 436 deletions
|
|
@ -1,13 +1,13 @@
|
|||
//! The `Window` struct and associated types.
|
||||
use std::fmt;
|
||||
|
||||
use platform_impl;
|
||||
use error::{ExternalError, NotSupportedError, OsError};
|
||||
use event_loop::EventLoopWindowTarget;
|
||||
use monitor::{AvailableMonitorsIter, MonitorHandle};
|
||||
use dpi::{LogicalPosition, LogicalSize};
|
||||
use crate::platform_impl;
|
||||
use crate::error::{ExternalError, NotSupportedError, OsError};
|
||||
use crate::event_loop::EventLoopWindowTarget;
|
||||
use crate::monitor::{AvailableMonitorsIter, MonitorHandle};
|
||||
use crate::dpi::{LogicalPosition, LogicalSize};
|
||||
|
||||
pub use icon::*;
|
||||
pub use crate::icon::*;
|
||||
|
||||
/// Represents a window.
|
||||
///
|
||||
|
|
@ -35,7 +35,7 @@ pub struct Window {
|
|||
}
|
||||
|
||||
impl fmt::Debug for Window {
|
||||
fn fmt(&self, fmtr: &mut fmt::Formatter) -> fmt::Result {
|
||||
fn fmt(&self, fmtr: &mut fmt::Formatter<'_>) -> fmt::Result {
|
||||
fmtr.pad("Window { .. }")
|
||||
}
|
||||
}
|
||||
|
|
@ -71,7 +71,7 @@ pub struct WindowBuilder {
|
|||
}
|
||||
|
||||
impl fmt::Debug for WindowBuilder {
|
||||
fn fmt(&self, fmtr: &mut fmt::Formatter) -> fmt::Result {
|
||||
fn fmt(&self, fmtr: &mut fmt::Formatter<'_>) -> fmt::Result {
|
||||
fmtr.debug_struct("WindowBuilder")
|
||||
.field("window", &self.window)
|
||||
.finish()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue