Remove fn main from doctest (and also remove edition2018 cause I think it isn't useful)

Fix clippy "warning: needless `fn main` in doctest"
This commit is contained in:
Waffle 2019-10-13 14:39:53 +03:00
parent d68ec00deb
commit 77b24eaa3f

View file

@ -44,15 +44,13 @@ pub enum InlineKeyboardButtonKind {
/// Build buttons /// Build buttons
/// ///
/// Example: /// Example:
/// ```edition2018 /// ```
/// use async_telegram_bot::types::InlineKeyboardButton; /// use async_telegram_bot::types::InlineKeyboardButton;
/// ///
/// fn main() { /// let url_button = InlineKeyboardButton::url(
/// let url_button = InlineKeyboardButton::url( /// "Text".to_string(),
/// "Text".to_string(), /// "http://url.com".to_string(),
/// "http://url.com".to_string(), /// );
/// );
/// }
/// ``` /// ```
impl InlineKeyboardButton { impl InlineKeyboardButton {
pub fn url(text: String, url: String) -> InlineKeyboardButton { pub fn url(text: String, url: String) -> InlineKeyboardButton {