LINUX.ORG.RU

История изменений

Исправление Virtuos86, (текущая версия) :

https://blog.rust-lang.org/2018/05/29/Rust-1.26.1.html

Чтобы не начинать новый срач^W^Wновый тред, краткая сводка:

  • RLS no longer interferes with command line builds
  • Rustfmt stopped badly formatting text in some cases
  • Returning from main via impl Trait where the Trait is not Termination is no longer permitted
  • ::<> (turbofish) no longer works for method arguments whose type is impl Trait
  • NaN > NaN no longer returns true in const contexts
  • rustup should no longer fail due to missing documentation on some platforms

Из интересного, main теперь при использовании impl Trait для описания возвращаемого значения не может возвращать типы, которые не реалилизуют типаж Termination (с оговоркой), и оператор «турбофиш» временно не будет работать для аргументов методов, описанных с помощью impl Trait (временно — до уточнения семантики взаимодействия):

struct Foo;

impl Foo {
    fn bar(&self, _arg: impl Copy) {}
}

fn main() {
    Foo.bar::<u32>(0); // на 1.26.1 stable не соберется
}

Исходная версия Virtuos86, :

Rust 1.26.1

https://blog.rust-lang.org/2018/05/29/Rust-1.26.1.html Чтобы не начинать новый срач^W^Wновый тред, краткая сводка:

  • RLS no longer interferes with command line builds
  • Rustfmt stopped badly formatting text in some cases
  • Returning from main via impl Trait where the Trait is not Termination is no longer permitted
  • ::<> (turbofish) no longer works for method arguments whose type is impl Trait
  • NaN > NaN no longer returns true in const contexts
  • rustup should no longer fail due to missing documentation on some platforms

Из интересного, main теперь при использовании impl Trait для описания возвращаемого значения не может возвращать типы, которые не реалилизуют типаж Termination (с оговоркой), и оператор «турбофиш» временно не будет работать для аргументов методов, описанных с помощью impl Trait (временно — до уточнения семантики взаимодействия):

struct Foo;

impl Foo {
    fn bar(&self, _arg: impl Copy) {}
}

fn main() {
    Foo.bar::<u32>(0); // на 1.26.1 stable не соберется
}