Commit graph

21 commits

Author SHA1 Message Date
ryoon
d5296f822f Update to 1.25.0
Changelog:
Version 1.25.0 (2018-03-29)
Language

    Stabilised #[repr(align(x))]. RFC 1358
    You can now use nested groups of imports. e.g. use std::{fs::File, io::Read, path::{Path, PathBuf}};
    You can now have | at the start of a match arm. e.g.

enum Foo { A, B, C }

fn main() {
    let x = Foo::A;
    match x {
        | Foo::A
        | Foo::B => println!("AB"),
        | Foo::C => println!("C"),
    }
}

Compiler

    Upgraded to LLVM 6.
    Added -C lto=val option.
    Added i586-unknown-linux-musl target

Libraries

    Impl Send for process::Command on Unix.
    Impl PartialEq and Eq for ParseCharError.
    UnsafeCell::into_inner is now safe.
    Implement libstd for CloudABI.
    Float::{from_bits, to_bits} is now available in libcore.
    Implement AsRef<Path> for Component
    Implemented Write for Cursor<&mut Vec<u8>>
    Moved Duration to libcore.

Stabilized APIs

    Location::column
    ptr::NonNull

The following functions can now be used in a constant expression. eg. static MINUTE: Duration = Duration::from_secs(60);

    Duration::new
    Duration::from_secs
    Duration::from_millis

Cargo

    cargo new no longer removes rust or rs prefixs/suffixs.
    cargo new now defaults to creating a binary crate, instead of a library crate.

Misc

    Rust by example is now shipped with new releases

Compatibility Notes

    Deprecated net::lookup_host.
    rustdoc has switched to pulldown as the default markdown renderer.
    The borrow checker was sometimes incorrectly permitting overlapping borrows around indexing operations (see #47349). This has been fixed (which also enabled some correct code that used to cause errors (e.g. #33903 and #46095).
    Removed deprecated unstable attribute #[simd].
2018-04-04 12:16:46 +00:00
ryoon
ab803a6bb2 Update to 1.24.1
Changelog:
    Do not abort when unwinding through FFI (this reverts behavior added
      in 1.24.0)
    Emit UTF-16 files for linker arguments on Windows
    Make the error index generator work again
    Cargo will warn on Windows 7 if an update is needed.
2018-03-03 22:11:26 +00:00
triaxx
862e6d4a6d Enable FreeBSD support 2018-03-02 05:59:18 +00:00
ryoon
a325dccc60 Update to 1.24.0
* Disable SunOS support for a while

Changelog:
Version 1.24.0 (2018-02-15)
Language
    External sysv64 ffi is now available. eg. extern "sysv64" fn foo () {}

Compiler
    rustc now uses 16 codegen units by default for release builds. For
      the fastest builds, utilize codegen-units=1.
    Added armv4t-unknown-linux-gnueabi target.
    Add aarch64-unknown-openbsd support

Libraries
    str::find::<char> now uses memchr. This should lead to a 10x improvement
      in performance in the majority of cases.
    OsStr's Debug implementation is now lossless and consistent with Windows.
    time::{SystemTime, Instant} now implement Hash.
    impl From<bool> for AtomicBool
    impl From<{CString, &CStr}> for {Arc<CStr>, Rc<CStr>}
    impl From<{OsString, &OsStr}> for {Arc<OsStr>, Rc<OsStr>}
    impl From<{PathBuf, &Path}> for {Arc<Path>, Rc<Path>}
    float::from_bits now just uses transmute. This provides some optimisations
      from LLVM.
    Copied AsciiExt methods onto char
    Remove T: Sized requirement on ptr::is_null()
    impl From<RecvError> for {TryRecvError, RecvTimeoutError}
    Optimised f32::{min, max} to generate more efficent x86 assembly
    [u8]::contains now uses memchr which provides a 3x speed improvement

Stabilized APIs
    RefCell::replace
    RefCell::swap
    atomic::spin_loop_hint

The following functions can now be used in a constant expression.
eg. let buffer: [u8; size_of::<usize>()];, static COUNTER: AtomicUsize =
AtomicUsize::new(1);

    AtomicBool::new
    AtomicUsize::new
    AtomicIsize::new
    AtomicPtr::new
    Cell::new
    {integer}::min_value
    {integer}::max_value
    mem::size_of
    mem::align_of
    ptr::null
    ptr::null_mut
    RefCell::new
    UnsafeCell::new

Cargo
    Added a workspace.default-members config that overrides implied --all
      in virtual workspaces.
    Enable incremental by default on development builds. Also added
      configuration keys to Cargo.toml and .cargo/config to disable on
      a per-project or global basis respectively.

Misc
Compatibility Notes
    Floating point types Debug impl now always prints a decimal point.
    Ipv6Addr now rejects superfluous ::'s in IPv6 addresses This is in
      accordance with IETF RFC 4291 Sec. 2.2.
    Unwinding will no longer go past FFI boundaries, and will instead abort.
    Formatter::flags method is now deprecated. The sign_plus, sign_minus,
      alternate, and sign_aware_zero_pad should be used instead.
    Leading zeros in tuple struct members is now an error
    column!() macro is one-based instead of zero-based
    fmt::Arguments can no longer be shared across threads
    Access to #[repr(packed)] struct fields is now unsafe
    Cargo sets a different working directory for the compiler
2018-02-18 12:12:54 +00:00
ryoon
a4a642f3e3 Enable SunOS/Solaris support
However SunOS build fails with internal libtool.
2018-01-09 11:47:33 +00:00
ryoon
f166e97b4c Update to 1.23.0
* Disable Solaris/SunOS suppprt for a while

Changelog:
# What's in 1.23.0 stable

New year, new Rust! For our first improvement today, we now avoid
some unnecessary copies in certain situations. We've seen memory
usage of using rustc to drop 5-10% with this change; it may be
different with your programs.

The documentation team has been on a long journey to move rustdoc
to use CommonMark. Previously, rustdoc never guaranteed which
markdown rendering engine it used, but we're finally committing to
CommonMark. As part of this release, we render the documentation
with our previous renderer, Hoedown, but also render it with a
CommonMark compliant renderer, and warn if there are any differences.
There should be a way for you to modify the syntax you use to render
correctly under both; we're not aware of any situations where this
is impossible. Docs team member Guillaume Gomez has written a blog
post showing some common differences and how to solve them. In a
future release, we will switch to using the CommonMark renderer by
default. This warning landed in nightly in May of last year, and
has been on by default since October of last year, so many crates
have already fixed any issues that they've found.

In other documentation news, historically, Cargo's docs have been
a bit strange. Rather than being on doc.rust-lang.org, they've been
at doc.crates.io. With this release, that's changing. You can now
find Cargo's docs at doc.rust-lang.org/cargo. Additionally, they've
been converted to the same format as our other long-form documentation.
We'll be adding a redirect from doc.crates.io to this page, and
you can expect to see more improvements and updates to Cargo's docs
throughout the year.

See the detailed release notes for more.

## Library stabilizations

As of Rust 1.0, a trait named AsciiExt existed to provide ASCII
related functionality on u8, char, [u8], and str. To use it, you'd
write code like this:

use std::ascii::AsciiExt;

let ascii = 'a';
let non_ascii = '❤';
let int_ascii = 97;

assert!(ascii.is_ascii());
assert!(!non_ascii.is_ascii());
assert!(int_ascii.is_ascii());

In Rust 1.23, these methods are now defined directly on those types,
and so you no longer need to import the trait. Thanks to our
stability guarantees, this trait still exists, so if you'd like to
still support Rust versions before Rust 1.23, you can do this:

#[allow(unused_imports)]
use std::ascii::AsciiExt;

...to suppress the related warning. Once you drop support for older
Rusts, you can remove both lines, and everything will continue to
work.

Additionally, a few new APIs were stabilized this release:

    The various std::sync::atomic types now implement From their
    non-atomic types. For example, let x = AtomicBool::from(true);.
    () now implements FromIterator<()>; check the PR for a neat
    use-case.  RwLock<T> has had its Send restriction lifted

See the detailed release notes for more.

## Cargo features

cargo check can now check your unit tests.

cargo uninstall can now uninstall more than one package in one
command.
2018-01-08 09:33:58 +00:00
jperkin
a4a9aa4a7a rust: Restore SunOS support. 2018-01-04 15:18:50 +00:00
maya
b7cc239119 rust: revert distinfo:r1.13
This is likely an accidental change and the distinfo uploaded was different.
PR pkg/52809
2017-12-20 05:38:21 +00:00
ryoon
3cd80f7575 Fix NetBSD/i386 8 build. Fix PR pkg/52809 2017-12-17 01:00:02 +00:00
maya
fb99f3af0a rust: don't filter out optimization flags. improves build time.
from a commit by semarie@openbsd
2017-12-07 12:12:44 +00:00
ryoon
c0971a3bf2 Update to 1.22.1
* Disable SunOS support for a while

Changelog:
Version 1.22.1 (2017-11-22)

    Update Cargo to fix an issue with macOS 10.13 "High Sierra"

Version 1.22.0 (2017-11-22)

Language
    non_snake_case lint now allows extern no-mangle functions
    Now accepts underscores in unicode escapes
    T op= &T now works for numeric types. eg. let mut x = 2; x += &8;
    types that impl Drop are now allowed in const and static types

Compiler
    rustc now defaults to having 16 codegen units at debug on supported
    platforms.
    rustc will no longer inline in codegen units when compiling for debug
    This should decrease compile times for debug builds.
    strict memory alignment now enabled on ARMv6
    Remove support for the PNaCl target le32-unknown-nacl

Libraries
    Allow atomic operations up to 32 bits on armv5te_unknown_linux_gnueabi
    Box<Error> now impls From<Cow<str>>
    std::mem::Discriminant is now guaranteed to be Send + Sync
    fs::copy now returns the length of the main stream on NTFS.
    Properly detect overflow in Instant += Duration.
    impl Hasher for {&mut Hasher, Box<Hasher>}
    impl fmt::Debug for SplitWhitespace.
    Option<T> now impls Try This allows for using ? with Option types.

Stabilized APIs
Cargo
    Cargo will now build multi file examples in subdirectories of the
    examples folder that have a main.rs file.
    Changed [root] to [package] in Cargo.lock Packages with the old
    format will continue to work and can be updated with cargo update.
    Now supports vendoring git repositories

Misc
    libbacktrace is now available on Apple platforms.
    Stabilised the compile_fail attribute for code fences in doc-comments.
    This now lets you specify that a given code example will fail to compile.

Compatibility Notes

    The minimum Android version that rustc can build for has been
    bumped to 4.0 from 2.3
    Allowing T op= &T for numeric types has broken some type inference cases
2017-11-28 00:07:27 +00:00
jperkin
f217fd513f rust: Restore SunOS support. Switch back to configure script.
No changes intended on other platforms, the configure script arguments
should be identical to those previously found in config.toml.  Doing it
this way makes it a lot easier to have per-OS configuration.
2017-11-16 19:48:24 +00:00
ryoon
e231db991c Update to 1.21.0
Changelog:
Version 1.21.0 (2017-10-12)
==========================

Language
--------
- [You can now use static references for literals.][43838]
  Example:
  ```rust
  fn main() {
      let x: &'static u32 = &0;
  }
  ```
- [Relaxed path syntax. Optional `::` before `<` is now allowed in all contexts.][43540]
  Example:
  ```rust
  my_macro!(Vec<i32>::new); // Always worked
  my_macro!(Vec::<i32>::new); // Now works
  ```

Compiler
--------
- [Upgraded jemalloc to 4.5.0][43911]
- [Enabled unwinding panics on Redox][43917]
- [Now runs LLVM in parallel during translation phase.][43506]
  This should reduce peak memory usage.

Libraries
---------
- [Generate builtin impls for `Clone` for all arrays and tuples that
  are `T: Clone`][43690]
- [`Stdin`, `Stdout`, and `Stderr` now implement `AsRawFd`.][43459]
- [`Rc` and `Arc` now implement `From<&[T]> where T: Clone`, `From<str>`,
  `From<String>`, `From<Box<T>> where T: ?Sized`, and `From<Vec<T>>`.][42565]

Stabilized APIs
---------------

[`std::mem::discriminant`]

Cargo
-----
- [You can now call `cargo install` with multiple package names][cargo/4216]
- [Cargo commands inside a virtual workspace will now implicitly
  pass `--all`][cargo/4335]
- [Added a `[patch]` section to `Cargo.toml` to handle
  prepublication dependencies][cargo/4123] [RFC 1969]
- [`include` & `exclude` fields in `Cargo.toml` now accept gitignore
  like patterns][cargo/4270]
- [Added the `--all-targets` option][cargo/4400]
- [Using required dependencies as a feature is now deprecated and emits
  a warning][cargo/4364]


Misc
----
- [Cargo docs are moving][43916]
  to [doc.rust-lang.org/cargo](https://doc.rust-lang.org/cargo)
- [The rustdoc book is now available][43863]
  at [doc.rust-lang.org/rustdoc](https://doc.rust-lang.org/rustdoc)
- [Added a preview of RLS has been made available through rustup][44204]
  Install with `rustup component add rls-preview`
- [`std::os` documentation for Unix, Linux, and Windows now appears on doc.rust-lang.org][43348]
  Previously only showed `std::os::unix`.

Compatibility Notes
-------------------
- [Changes in method matching against higher-ranked types][43880] This may cause
  breakage in subtyping corner cases. [A more in-depth explanation is available.][info/43880]
- [rustc's JSON error output's byte position start at top of file.][42973]
  Was previously relative to the rustc's internal `CodeMap` struct which
  required the unstable library `libsyntax` to correctly use.
- [`unused_results` lint no longer ignores booleans][43728]

[42565]: https://github.com/rust-lang/rust/pull/42565
[42973]: https://github.com/rust-lang/rust/pull/42973
[43348]: https://github.com/rust-lang/rust/pull/43348
[43459]: https://github.com/rust-lang/rust/pull/43459
[43506]: https://github.com/rust-lang/rust/pull/43506
[43540]: https://github.com/rust-lang/rust/pull/43540
[43690]: https://github.com/rust-lang/rust/pull/43690
[43728]: https://github.com/rust-lang/rust/pull/43728
[43838]: https://github.com/rust-lang/rust/pull/43838
[43863]: https://github.com/rust-lang/rust/pull/43863
[43880]: https://github.com/rust-lang/rust/pull/43880
[43911]: https://github.com/rust-lang/rust/pull/43911
[43916]: https://github.com/rust-lang/rust/pull/43916
[43917]: https://github.com/rust-lang/rust/pull/43917
[44204]: https://github.com/rust-lang/rust/pull/44204
[cargo/4123]: https://github.com/rust-lang/cargo/pull/4123
[cargo/4216]: https://github.com/rust-lang/cargo/pull/4216
[cargo/4270]: https://github.com/rust-lang/cargo/pull/4270
[cargo/4335]: https://github.com/rust-lang/cargo/pull/4335
[cargo/4364]: https://github.com/rust-lang/cargo/pull/4364
[cargo/4400]: https://github.com/rust-lang/cargo/pull/4400
[RFC 1969]: https://github.com/rust-lang/rfcs/pull/1969
[info/43880]: https://github.com/rust-lang/rust/issues/44224#issuecomment-330058902
[`std::mem::discriminant`]: https://doc.rust-lang.org/std/mem/fn.discriminant.html
2017-11-03 22:04:10 +00:00
ryoon
f7b9a3f714 Provide my private bootstrap kit for i686-unknown-netbsd
* Fix build of www/firefox-56.0 with this
2017-10-21 12:15:56 +00:00
ryoon
8a89f61f7f Update to 1.20.0
* Disable SunOS/Solaris support because newer bootstrap is not available
* Include Rust libraries and Cargo

Changelog:
Version 1.20.0 (2017-08-31)
Language

    Associated constants are now stabilised.
    A lot of macro bugs are now fixed.

Compiler

    Struct fields are now properly coerced to the expected field type.
    Enabled wasm LLVM backend WASM can now be built with the wasm32-experimental-emscripten target.
    Changed some of the error messages to be more helpful.
    Add support for RELRO(RELocation Read-Only) for platforms that support it.
    rustc now reports the total number of errors on compilation failure previously this was only the number of errors in the pass that failed.
    Expansion in rustc has been sped up 29x.
    added msp430-none-elf target.
    rustc will now suggest one-argument enum variant to fix type mismatch when applicable
    Fixes backtraces on Redox
    rustc now identifies different versions of same crate when absolute paths of different types match in an error message.

Libraries

    Relaxed Debug constraints on {HashMap,BTreeMap}::{Keys,Values}.
    Impl PartialEq, Eq, PartialOrd, Ord, Debug, Hash for unsized tuples.
    Impl fmt::{Display, Debug} for Ref, RefMut, MutexGuard, RwLockReadGuard, RwLockWriteGuard
    Impl Clone for DefaultHasher.
    Impl Sync for SyncSender.
    Impl FromStr for char
    Fixed how {f32, f64}::{is_sign_negative, is_sign_positive} handles NaN.
    allow messages in the unimplemented!() macro. ie. unimplemented!("Waiting for 1.21 to be stable")
    pub(restricted) is now supported in the thread_local! macro.
    Upgrade to Unicode 10.0.0
    Reimplemented {f32, f64}::{min, max} in Rust instead of using CMath.
    Skip the main thread's manual stack guard on Linux
    Iterator::nth for ops::{Range, RangeFrom} is now done in O(1) time
    #[repr(align(N))] attribute max number is now 2^31 - 1. This was previously 2^15.
    {OsStr, Path}::Display now avoids allocations where possible

Stabilized APIs

    CStr::into_c_string
    CString::as_c_str
    CString::into_boxed_c_str
    Chain::get_mut
    Chain::get_ref
    Chain::into_inner
    Option::get_or_insert_with
    Option::get_or_insert
    OsStr::into_os_string
    OsString::into_boxed_os_str
    Take::get_mut
    Take::get_ref
    Utf8Error::error_len
    char::EscapeDebug
    char::escape_debug
    compile_error!
    f32::from_bits
    f32::to_bits
    f64::from_bits
    f64::to_bits
    mem::ManuallyDrop
    slice::sort_unstable_by_key
    slice::sort_unstable_by
    slice::sort_unstable
    str::from_boxed_utf8_unchecked
    str::as_bytes_mut
    str::as_bytes_mut
    str::from_utf8_mut
    str::from_utf8_unchecked_mut
    str::get_mut
    str::get_unchecked_mut
    str::get_unchecked
    str::get
    str::into_boxed_bytes

Cargo

    Cargo API token location moved from ~/.cargo/config to ~/.cargo/credentials.
    Cargo will now build main.rs binaries that are in sub-directories of src/bin. ie. Having src/bin/server/main.rs and src/bin/client/main.rs generates target/debug/server and target/debug/client
    You can now specify version of a binary when installed through cargo install using --vers.
    Added --no-fail-fast flag to cargo to run all benchmarks regardless of failure.
    Changed the convention around which file is the crate root.
    The include/exclude property in Cargo.toml now accepts gitignore paths instead of glob patterns. Glob patterns are now deprecated.

Compatibility Notes

    Functions with 'static in their return types will now not be as usable as if they were using lifetime parameters instead.
    The reimplementation of {f32, f64}::is_sign_{negative, positive} now takes the sign of NaN into account where previously didn't.

Version 1.19.0 (2017-07-20)
Language

    Numeric fields can now be used for creating tuple structs. RFC 1506 For example struct Point(u32, u32); let x = Point { 0: 7, 1: 0 };.
    Macro recursion limit increased to 1024 from 64.
    Added lint for detecting unused macros.
    loop can now return a value with break. RFC 1624 For example: let x = loop { break 7; };
    C compatible unions are now available. RFC 1444 They can only contain Copy types and cannot have a Drop implementation. Example: union Foo { bar: u8, baz: usize }
    Non capturing closures can now be coerced into fns, RFC 1558 Example: let foo: fn(u8) -> u8 = |v: u8| { v };

Compiler

    Add support for bootstrapping the Rust compiler toolchain on Android.
    Change arm-linux-androideabi to correspond to the armeabi official ABI. If you wish to continue targeting the armeabi-v7a ABI you should use --target armv7-linux-androideabi.
    Fixed ICE when removing a source file between compilation sessions.
    Minor optimisation of string operations.
    Compiler error message is now aborting due to previous error(s) instead of aborting due to N previous errors This was previously inaccurate and would only count certain kinds of errors.
    The compiler now supports Visual Studio 2017
    The compiler is now built against LLVM 4.0.1 by default
    Added a lot of new error codes
    Added target-feature=+crt-static option RFC 1721 Which allows libraries with C Run-time Libraries(CRT) to be statically linked.
    Fixed various ARM codegen bugs

Libraries

    String now implements FromIterator<Cow<'a, str>> and Extend<Cow<'a, str>>
    Vec now implements From<&mut [T]>
    Box<[u8]> now implements From<Box<str>>
    SplitWhitespace now implements Clone
    [u8]::reverse is now 5x faster and [u16]::reverse is now 1.5x faster
    eprint! and eprintln! macros added to prelude. Same as the print! macros, but for printing to stderr.

Stabilized APIs

    OsString::shrink_to_fit
    cmp::Reverse
    Command::envs
    thread::ThreadId

Cargo

    Build scripts can now add environment variables to the environment the crate is being compiled in. Example: println!("cargo:rustc-env=FOO=bar");
    Subcommands now replace the current process rather than spawning a new child process
    Workspace members can now accept glob file patterns
    Added --all flag to the cargo bench subcommand to run benchmarks of all the members in a given workspace.
    Updated libssh2-sys to 0.2.6
    Target directory path is now in the cargmetadata
    Cargo no longer checks out a local working directory for the crates.io index This should provide smaller file size for the registry, and improve cloning times, especially on Windows machines.
    Added an --exclude option for excluding certai using the --all option
    Cargo will now automatically retry when receiving a 5xx error from crates.io
    The --features option now accepts multiple comma or space delimited values.
    Added support for custom target specific runners

Misc

    Added ow prefer to download rust packages with XZ compression over GZip packages.
    Added the ability to escape # in rust documentation By adding additional #'s ie. ## is now #

Compatibility Notes

    MutexGuard<T> may only be Sync if T is Sync.
    -Z flagning for a year previous to this.
    As a result of the -Z flag change, the cargo-check plugin no longer works. Users should migrate to the built-in check command, which has been available since 1.16.
    Ending a float literal with ._ is now a hard erro  use ::self::foo; is now a hard error. self paths are always relative while the :: prefix makes a path absolute, but was ignored and the path was relative regardless.
    Floating point constants in match patterns is now a hard error This was previously ts that don't derive PartialEq & Eq used match patterns is now a hard error This was previously a warning.
    Lifetimes named '_ are no longer allowed. This was previously a warning.
    From the pound escape, lines consisting of multiple #s are now visible
    It is an error to reexport private enum variants. This is known to break a number of crates that depend on an older version of mustache.
    On Windows, if VCINSTALLDIR is set incorrectly, rustc will try to use it to find the linker, and the build will fail where it did not previously

Version 1.18.0 (2017-06-08)
Language

    Stabilize pub(restricted) pub can now accept a module path to make the item visible to just that module tree. Also accepts the keyword crate to make something public to the whole crate but not users of the library. Example: pub(crate) mod utils;. RFC 1422.
    Stabilize #![windows_subsystem] attribute conservative exposure of the /SUBSYSTEM linker flag on Windows platforms. RFC 1665.
    Refactor of trait object type parsing Now ty in macros can accept types like Write + Send, trailing + are now supported in trait objects, and better error reporting for trait objects starting with ?Sized.
    0e+10 is now a valid floating point literal
    Now warns if you bind a lifetime parameter to 'static
    Tuples, Enum variant fields, and structs with no repr attribute or with #[repr(Rust)] are reordered to minimize padding and produce a smaller representation in some cases.

Compiler

    rustc can now emit mir with --emit mir
    Improved LLVM IR for trivial functions
    Added explanation for E0090(Wrong number of lifetimes are supplied)
    rustc compilation is now 15%-20% faster Thanks to optimisation opportunities found through profiling
    Improved backtrace formatting when panicking

Libraries

    Specialized Vec::from_iter being passed vec::IntoIter if the iterator hasn't been advanced the original Vec is reassembled with no actual iteration or reallocation.
    Simplified HashMap Bucket interface provides performance improvements for iterating and cloning.
    Specialize Vec::from_elem to use calloc
    Fixed Race condition in fs::create_dir_all
    No longer caching stdio on Windows
    Optimized insertion sort in slice insertion sort in some cases 2.50%~ faster and in one case now 12.50% faster.
    Optimized AtomicBool::fetch_nand

Stabilized APIs

    Child::try_wait
    HashMap::retain
    HashSet::retain
    PeekMut::pop
    TcpStream::peek
    UdpSocket::peek
    UdpSocket::peek_from

Cargo

    Added partial Pijul support Pijul is a version control system in Rust. You can now create new cargo projects with Pijul using cargo new --vcs pijul
    Now always emits build script warnings for crates that fail to build
    Added Android build support
    Added --bins and --tests flags now you can build all programs of a certain type, for example cargo build --bins will build all binaries.
    Added support for haiku

Misc

    rustdoc can now use pulldown-cmark with the --enable-commonmark flag
    Added rust-winbg script for better debugging on Windows
    Rust now uses the official cross compiler for NetBSD
    rustdoc now accepts # at the start of files
    Fixed jemalloc support for musl

Compatibility Notes

    Changes to how the 0 flag works in format! Padding zeroes are now always placed after the sign if it exists and before the digits. With the # flag the zeroes are placed after the prefix and before the digits.

    Due to the struct field optimisation, using transmute on structs that have no repr attribute or #[repr(Rust)] will no longer work. This has always been undefined behavior, but is now more likely to break in practice.

    The refactor of trait object type parsing fixed a bug where + was receiving the wrong priority parsing things like &for<'a> Tr<'a> + Send as &(for<'a> Tr<'a> + Send) instead of (&for<'a> Tr<'a>) + Send

    Overlapping inherent impls are now a hard error

    PartialOrd and Ord must agree on the ordering.

    rustc main.rs -o out --emit=asm,llvm-ir Now will output out.asm and out.ll instead of only one of the filetypes.

    calling a function that returns Self will no longer work when the size of Self cannot be statically determined.

    rustc now builds with a "pthreads" flavour of MinGW for Windows GNU this has caused a few regressions namely:
        Changed the link order of local static/dynamic libraries (respecting the order on given rather than having the compiler reorder).
        Changed how MinGW is linked, native code linked to dynamic libraries may require manually linking to the gcc support library (for the native code itself)

Version 1.17.0 (2017-04-27)
Language

    The lifetime of statics and consts defaults to 'static. RFC 1623
    Fields of structs may be initialized without duplicating the field/variable names. RFC 1682
    Self may be included in the where clause of impls. RFC 1647
    When coercing to an unsized type lifetimes must be equal. That is, there is no subtyping between T and U when T: Unsize<U>. For example, coercing &mut [&'a X; N] to &mut [&'b X] requires 'a be equal to 'b. Soundness fix.
    Values passed to the indexing operator, [], automatically coerce
    Static variables may contain references to other statics

Compiler

    Exit quickly on only --emit dep-info
    Make -C relocation-model more correctly determine whether the linker creates a position-independent executable
    Add -C overflow-checks to directly control whether integer overflow panics
    The rustc type checker now checks items on demand instead of in a single in-order pass. This is mostly an internal refactoring in support of future work, including incremental type checking, but also resolves RFC 1647, allowing Self to appear in impl where clauses.
    Optimize vtable loads
    Turn off vectorization for Emscripten targets
    Provide suggestions for unknown macros imported with use
    Fix ICEs in path resolution
    Strip exception handling code on Emscripten when panic=abort
    Add clearer error message using &str + &str

Stabilized APIs

    Arc::into_raw
    Arc::from_raw
    Arc::ptr_eq
    Rc::into_raw
    Rc::from_raw
    Rc::ptr_eq
    Ordering::then
    Ordering::then_with
    BTreeMap::range
    BTreeMap::range_mut
    collections::Bound
    process::abort
    ptr::read_unaligned
    ptr::write_unaligned
    Result::expect_err
    Cell::swap
    Cell::replace
    Cell::into_inner
    Cell::take

Libraries

    BTreeMap and BTreeSet can iterate over ranges
    Cell can store non-Copy types. RFC 1651
    String implements FromIterator<&char>
    Box implements a number of new conversions: From<Box<str>> for String, From<Box<[T]>> for Vec<T>, From<Box<CStr>> for CString, From<Box<OsStr>> for OsString, From<Box<Path>> for PathBuf, Into<Box<str>> for String, Into<Box<[T]>> for Vec<T>, Into<Box<CStr>> for CString, Into<Box<OsStr>> for OsString, Into<Box<Path>> for PathBuf, Default for Box<str>, Default for Box<CStr>, Default for Box<OsStr>, From<&CStr> for Box<CStr>, From<&OsStr> for Box<OsStr>, From<&Path> for Box<Path>
    ffi::FromBytesWithNulError implements Error and Display
    Specialize PartialOrd<A> for [A] where A: Ord
    Slightly optimize slice::sort
    Add ToString trait specialization for Cow<'a, str> and String
    Box<[T]> implements From<&[T]> where T: Copy, Box<str> implements From<&str>
    IpAddr implements From for various arrays. SocketAddr implements From<(I, u16)> where I: Into<IpAddr>
    format! estimates the needed capacity before writing a string
    Support unprivileged symlink creation in Windows
    PathBuf implements Default
    Implement PartialEq<[A]> for VecDeque<A>
    HashMap resizes adaptively to guard against DOS attacks and poor hash functions.

Cargo

    Add cargo check --all
    Add an option to ignore SSL revocation checking
    Add cargo run --package
    Add required_features
    Assume build.rs is a build script
    Find workspace via workspace_root link in containing member

Misc

    Documentation is rendered with mdbook instead of the obsolete, in-tree rustbook
    The "Unstable Book" documents nightly-only features
    Improve the style of the sidebar in rustdoc output
    Configure build correctly on 64-bit CPU's with the armhf ABI
    Fix MSP430 breakage due to i128
    Preliminary Solaris/SPARCv9 support
    rustc is linked statically on Windows MSVC targets, allowing it to run without installing the MSVC runtime.
    rustdoc --test includes file names in test names
    This release includes builds of std for sparc64-unknown-linux-gnu, aarch64-unknown-linux-fuchsia, and x86_64-unknown-linux-fuchsia.
    Initial support for aarch64-unknown-freebsd
    Initial support for i686-unknown-netbsd
    This release no longer includes the old makefile build system. Rust is built with a custom build system, written in Rust, and with Cargo.
    Add Debug implementations for libcollection structs
    TypeId implements PartialOrd and Ord
    --test-threads=0 produces an error
    rustup installs documentation by default
    The Rust source includes NatVis visualizations. These can be used by WinDbg and Visual Studio to improve the debugging experience.

Compatibility Notes

    Rust 1.17 does not correctly detect the MSVC 2017 linker. As a workaround, either use MSVC 2015 or run vcvars.bat.
    When coercing to an unsized type lifetimes must be equal. That is, disallow subtyping between T and U when T: Unsize<U>, e.g. coercing &mut [&'a X; N] to &mut [&'b X] requires 'a be equal to 'b. Soundness fix.
    format! and Display::to_string panic if an underlying formatting implementation returns an error. Previously the error was silently ignored. It is incorrect for write_fmt to return an error when writing to a string.
    In-tree crates are verified to be unstable. Previously, some minor crates were marked stable and could be accessed from the stable toolchain.
    Rust git source no longer includes vendored crates. Those that need to build with vendored crates should build from release tarballs.
    Fix inert attributes from proc_macro_derives
    During crate resolution, rustc prefers a crate in the sysroot if two crates are otherwise identical. Unlikely to be encountered outside the Rust build system.
    Fixed bugs around how type inference interacts with dead-code. The existing code generally ignores the type of dead-code unless a type-hint is provided; this can cause surprising inference interactions particularly around defaulting. The new code uniformly ignores the result type of dead-code.
    Tuple-struct constructors with private fields are no longer visible
    Lifetime parameters that do not appear in the arguments are now considered early-bound, resolving a soundness bug (#32330). The hr_lifetime_in_assoc_type future-compatibility lint has been in effect since April of 2016.
    rustdoc: fix doctests with non-feature crate attributes
    Make transmuting from fn item types to pointer-sized types a hard error
2017-09-30 04:42:43 +00:00
jperkin
df855acf79 Update lang/rust to 1.16.0. Changes since 1.15.1:
Version 1.16.0 (2017-03-16)
===========================

Language
--------

* Lifetimes in statics and consts default to `'static`. [RFC 1623]
* [The compiler's `dead_code` lint now accounts for type aliases][38051].
* [Uninhabitable enums (those without any variants) no longer permit wildcard
  match patterns][38069]
* [Clean up semantics of `self` in an import list][38313]
* [`Self` may appear in `impl` headers][38920]
* [`Self` may appear in struct expressions][39282]

Compiler
--------

* [`rustc` now supports `--emit=metadata`, which causes rustc to emit
  a `.rmeta` file containing only crate metadata][38571]. This can be
  used by tools like the Rust Language Service to perform
  metadata-only builds.
* [Levenshtein based typo suggestions now work in most places, while
  previously they worked only for fields and sometimes for local
  variables][38927]. Together with the overhaul of "no
  resolution"/"unexpected resolution" errors (#[38154]) they result in
  large and systematic improvement in resolution diagnostics.
* [Fix `transmute::<T, U>` where `T` requires a bigger alignment than
  `U`][38670]
* [rustc: use -Xlinker when specifying an rpath with ',' in it][38798]
* [`rustc` no longer attempts to provide "consider using an explicit
  lifetime" suggestions][37057]. They were inaccurate.

Stabilized APIs
---------------

* [`VecDeque::truncate`]
* [`VecDeque::resize`]
* [`String::insert_str`]
* [`Duration::checked_add`]
* [`Duration::checked_sub`]
* [`Duration::checked_div`]
* [`Duration::checked_mul`]
* [`str::replacen`]
* [`str::repeat`]
* [`SocketAddr::is_ipv4`]
* [`SocketAddr::is_ipv6`]
* [`IpAddr::is_ipv4`]
* [`IpAddr::is_ipv6`]
* [`Vec::dedup_by`]
* [`Vec::dedup_by_key`]
* [`Result::unwrap_or_default`]
* [`<*const T>::wrapping_offset`]
* [`<*mut T>::wrapping_offset`]
* `CommandExt::creation_flags`
* [`File::set_permissions`]
* [`String::split_off`]

Libraries
---------

* [`[T]::binary_search` and `[T]::binary_search_by_key` now take
  their argument by `Borrow` parameter][37761]
* [All public types in std implement `Debug`][38006]
* [`IpAddr` implements `From<Ipv4Addr>` and `From<Ipv6Addr>`][38327]
* [`Ipv6Addr` implements `From<[u16; 8]>`][38131]
* [Ctrl-Z returns from `Stdin.read()` when reading from the console on
  Windows][38274]
* [std: Fix partial writes in `LineWriter`][38062]
* [std: Clamp max read/write sizes on Unix][38062]
* [Use more specific panic message for `&str` slicing errors][38066]
* [`TcpListener::set_only_v6` is deprecated][38304]. This
  functionality cannot be achieved in std currently.
* [`writeln!`, like `println!`, now accepts a form with no string
  or formatting arguments, to just print a newline][38469]
* [Implement `iter::Sum` and `iter::Product` for `Result`][38580]
* [Reduce the size of static data in `std_unicode::tables`][38781]
* [`char::EscapeDebug`, `EscapeDefault`, `EscapeUnicode`,
  `CaseMappingIter`, `ToLowercase`, `ToUppercase`, implement
  `Display`][38909]
* [`Duration` implements `Sum`][38712]
* [`String` implements `ToSocketAddrs`][39048]

Cargo
-----

* [The `cargo check` command does a type check of a project without
  building it][cargo/3296]
* [crates.io will display CI badges from Travis and AppVeyor, if
  specified in Cargo.toml][cargo/3546]
* [crates.io will display categories listed in Cargo.toml][cargo/3301]
* [Compilation profiles accept integer values for `debug`, in addition
  to `true` and `false`. These are passed to `rustc` as the value to
  `-C debuginfo`][cargo/3534]
* [Implement `cargo --version --verbose`][cargo/3604]
* [All builds now output 'dep-info' build dependencies compatible with
  make and ninja][cargo/3557]
* [Build all workspace members with `build --all`][cargo/3511]
* [Document all workspace members with `doc --all`][cargo/3515]
* [Path deps outside workspace are not members][cargo/3443]

Misc
----

* [`rustdoc` has a `--sysroot` argument that, like `rustc`, specifies
  the path to the Rust implementation][38589]
* [The `armv7-linux-androideabi` target no longer enables NEON
  extensions, per Google's ABI guide][38413]
* [The stock standard library can be compiled for Redox OS][38401]
* [Rust has initial SPARC support][38726]. Tier 3. No builds
  available.
* [Rust has experimental support for Nvidia PTX][38559]. Tier 3. No
  builds available.
* [Fix backtraces on i686-pc-windows-gnu by disabling FPO][39379]

Compatibility Notes
-------------------

* [Uninhabitable enums (those without any variants) no longer permit wildcard
  match patterns][38069]
* In this release, references to uninhabited types can not be
  pattern-matched. This was accidentally allowed in 1.15.
* [The compiler's `dead_code` lint now accounts for type aliases][38051].
* [Ctrl-Z returns from `Stdin.read()` when reading from the console on
  Windows][38274]
* [Clean up semantics of `self` in an import list][38313]

[37057]: https://github.com/rust-lang/rust/pull/37057
[37761]: https://github.com/rust-lang/rust/pull/37761
[38006]: https://github.com/rust-lang/rust/pull/38006
[38051]: https://github.com/rust-lang/rust/pull/38051
[38062]: https://github.com/rust-lang/rust/pull/38062
[38062]: https://github.com/rust-lang/rust/pull/38622
[38066]: https://github.com/rust-lang/rust/pull/38066
[38069]: https://github.com/rust-lang/rust/pull/38069
[38131]: https://github.com/rust-lang/rust/pull/38131
[38154]: https://github.com/rust-lang/rust/pull/38154
[38274]: https://github.com/rust-lang/rust/pull/38274
[38304]: https://github.com/rust-lang/rust/pull/38304
[38313]: https://github.com/rust-lang/rust/pull/38313
[38314]: https://github.com/rust-lang/rust/pull/38314
[38327]: https://github.com/rust-lang/rust/pull/38327
[38401]: https://github.com/rust-lang/rust/pull/38401
[38413]: https://github.com/rust-lang/rust/pull/38413
[38469]: https://github.com/rust-lang/rust/pull/38469
[38559]: https://github.com/rust-lang/rust/pull/38559
[38571]: https://github.com/rust-lang/rust/pull/38571
[38580]: https://github.com/rust-lang/rust/pull/38580
[38589]: https://github.com/rust-lang/rust/pull/38589
[38670]: https://github.com/rust-lang/rust/pull/38670
[38712]: https://github.com/rust-lang/rust/pull/38712
[38726]: https://github.com/rust-lang/rust/pull/38726
[38781]: https://github.com/rust-lang/rust/pull/38781
[38798]: https://github.com/rust-lang/rust/pull/38798
[38909]: https://github.com/rust-lang/rust/pull/38909
[38920]: https://github.com/rust-lang/rust/pull/38920
[38927]: https://github.com/rust-lang/rust/pull/38927
[39048]: https://github.com/rust-lang/rust/pull/39048
[39282]: https://github.com/rust-lang/rust/pull/39282
[39379]: https://github.com/rust-lang/rust/pull/39379
[`<*const T>::wrapping_offset`]: https://doc.rust-lang.org/std/primitive.pointer.html#method.wrapping_offset
[`<*mut T>::wrapping_offset`]: https://doc.rust-lang.org/std/primitive.pointer.html#method.wrapping_offset
[`Duration::checked_add`]: https://doc.rust-lang.org/std/time/struct.Duration.html#method.checked_add
[`Duration::checked_div`]: https://doc.rust-lang.org/std/time/struct.Duration.html#method.checked_div
[`Duration::checked_mul`]: https://doc.rust-lang.org/std/time/struct.Duration.html#method.checked_mul
[`Duration::checked_sub`]: https://doc.rust-lang.org/std/time/struct.Duration.html#method.checked_sub
[`File::set_permissions`]: https://doc.rust-lang.org/std/fs/struct.File.html#method.set_permissions
[`IpAddr::is_ipv4`]: https://doc.rust-lang.org/std/net/enum.IpAddr.html#method.is_ipv4
[`IpAddr::is_ipv6`]: https://doc.rust-lang.org/std/net/enum.IpAddr.html#method.is_ipv6
[`Result::unwrap_or_default`]: https://doc.rust-lang.org/std/result/enum.Result.html#method.unwrap_or_default
[`SocketAddr::is_ipv4`]: https://doc.rust-lang.org/std/net/enum.SocketAddr.html#method.is_ipv4
[`SocketAddr::is_ipv6`]: https://doc.rust-lang.org/std/net/enum.SocketAddr.html#method.is_ipv6
[`String::insert_str`]: https://doc.rust-lang.org/std/string/struct.String.html#method.insert_str
[`String::split_off`]: https://doc.rust-lang.org/std/string/struct.String.html#method.split_off
[`Vec::dedup_by_key`]: https://doc.rust-lang.org/std/vec/struct.Vec.html#method.dedup_by_key
[`Vec::dedup_by`]: https://doc.rust-lang.org/std/vec/struct.Vec.html#method.dedup_by
[`VecDeque::resize`]:  https://doc.rust-lang.org/std/collections/vec_deque/struct.VecDeque.html#method.resize
[`VecDeque::truncate`]: https://doc.rust-lang.org/std/collections/vec_deque/struct.VecDeque.html#method.truncate
[`str::repeat`]: https://doc.rust-lang.org/std/primitive.str.html#method.repeat
[`str::replacen`]: https://doc.rust-lang.org/std/primitive.str.html#method.replacen
[cargo/3296]: https://github.com/rust-lang/cargo/pull/3296
[cargo/3301]: https://github.com/rust-lang/cargo/pull/3301
[cargo/3443]: https://github.com/rust-lang/cargo/pull/3443
[cargo/3511]: https://github.com/rust-lang/cargo/pull/3511
[cargo/3515]: https://github.com/rust-lang/cargo/pull/3515
[cargo/3534]: https://github.com/rust-lang/cargo/pull/3534
[cargo/3546]: https://github.com/rust-lang/cargo/pull/3546
[cargo/3557]: https://github.com/rust-lang/cargo/pull/3557
[cargo/3604]: https://github.com/rust-lang/cargo/pull/3604
[RFC 1623]: https://github.com/rust-lang/rfcs/blob/master/text/1623-static.md
2017-03-20 11:36:35 +00:00
jperkin
4b5aec7ba8 Update lang/rust to 1.15.1. Changes since 1.11.0 are too numerous to
list, but can be found here:

	https://github.com/rust-lang/rust/blob/master/RELEASES.md

Add a stage0-bootstrap target to simplify generation of bootstrap kits
for platforms which are not supported upstream (primarily SmartOS).
2017-02-23 09:35:16 +00:00
maya
7f28b9aeec rust: match newer versions of llvm, too.
while I didn't complete the build, it is likely necessary, as pkgsrc llvm
is 3.9 and doesn't match this test.
2017-01-08 14:38:13 +00:00
ryoon
ba33d41371 Restore accidentally deleted comment and use .NetBSD suffix
Thank you, jperkin@.
2016-09-13 12:37:08 +00:00
ryoon
ff942a2cbf Add NetBSD/amd64 support
This package must be built with pkgtools/cwrappers with USE_CWRAPPERS=yes.
2016-09-12 13:27:33 +00:00
jperkin
9fd0fe84f9 Import rust 1.11.0 as lang/rust into pkgsrc.
pkgsrc notes:

  * The build requires binary bootstraps built by the Rust team.  Due
    to the requirement that only the previous version is supported as
    a bootstrap compiler, and new versions of Rust are released every
    6 weeks, it is unlikely to be practical to build TNF bootstraps.
    Users should evaluate whether they trust binaries from upstream.

  * There is currently no SunOS bootstrap provided by the Rust team,
    so for now a version built by myself is provided by Joyent.

  * Only Darwin/Linux/SunOS are currently supported.  The Rust team do
    provide NetBSD bootstraps so support should be easy enough to add.

Information about Rust from the DESCR:

Rust is a systems programming language focused on three goals: safety,
speed, and concurrency.  It maintains these goals without having a
garbage collector, making it a useful language for a number of use cases
other languages aren't good at: embedding in other languages, programs
with specific space and time requirements, and writing low-level code,
like device drivers and operating systems.

It improves on current languages targeting this space by having a number
of compile-time safety checks that produce no runtime overhead, while
eliminating all data races.  Rust also aims to achieve "zero-cost
abstractions" even though some of these abstractions feel like those of
a high-level language.  Even then, Rust still allows precise control
like a low-level language would.
2016-09-06 10:36:49 +00:00