summary refs log tree commit diff
path: root/src/libstd/env.rs
AgeCommit message (Collapse)AuthorLines
2019-09-06A few cosmetic improvements to code & comments in liballoc and libcoreAlexander Regueiro-1/+1
2019-08-11docs: add stdlib env::var(_os) panicTom Milligan-0/+12
2019-07-22add support for hexagon-unknown-linux-muslBrian Cain-0/+5
2019-05-23Fix typo "spit_paths", add linkBrent Kerby-1/+3
2019-05-22Revert "Add implementations of last in terms of next_back on a bunch of ↵Steven Fackler-6/+0
DoubleEndedIterators." This reverts commit 3e86cf36b5114f201868bf459934fe346a76a2d4.
2019-05-15Auto merge of #60775 - hellow554:no_bitrig, r=joshtriplettbors-1/+0
Remove bitrig support from rust Resolves #60743 using `find` and `rg` I delete every occurence of "bitrig" in the sources, expect for the llvm submodule (is this correct?). There's also this file https://github.com/rust-lang/rls/blob/5b8e99bb61958ca8abcb7c5eda70521726be1065/rls-analysis/test_data/rust-analysis/libstd-af9bacceee784405.json which contains a bitrig string in it. What to do with that?
2019-05-14Rollup merge of #60130 - khuey:efficient_last, r=sfacklerMazdak Farrokhzad-0/+6
Add implementations of last in terms of next_back on a bunch of DoubleEndedIterators Provided a `DoubleEndedIterator` has finite length, `Iterator::last` is equivalent to `DoubleEndedIterator::next_back`. But searching forwards through the iterator when it's unnecessary is obviously not good for performance. I ran into this on one of the collection iterators. I tried adding appropriate overloads for a bunch of the iterator adapters like filter, map, etc, but I ran into a lot of type inference failures after doing so. The other interesting case is what to do with `Repeat`. Do we consider it part of the contract that `Iterator::last` will loop forever on it? The docs do say that the iterator will be evaluated until it returns None. This is also relevant for the adapters, it's trivially easy to observe whether a `Map` adapter invoked its closure a zillion times or just once for the last element.
2019-05-13Remove bitrig support from rustMarcel Hellwig-1/+0
2019-04-19Add implementations of last in terms of next_back on a bunch of ↵Kyle Huey-0/+6
DoubleEndedIterators. r?Manishearth
2019-04-17Document `Item` type in `std::env::SplitPaths` iterator.Nathan Kleyn-1/+7
Previously there wasn't any documentation to show what the type of `Item` was inside `std::env::SplitPaths`. Now, in the same format as other examples of docs in `srd` for `Iterator#Item`, we mention the type. This fixes #59543.
2019-03-31libstd: deny(elided_lifetimes_in_paths)Mazdak Farrokhzad-8/+8
2019-03-25SGX target: fix std unit testsJethro Beekman-1/+2
2019-02-28libstd => 2018Taiki Endo-13/+13
2019-02-17Use more impl header lifetime elisionScott McMurray-1/+1
There are two big categories of changes in here - Removing lifetimes from common traits that can essentially never user a lifetime from an input (particularly `Drop` & `Debug`) - Forwarding impls that are only possible because the lifetime doesn't matter (like `impl<R: Read + ?Sized> Read for &mut R`) I omitted things that seemed like they could be more controversial, like the handful of iterators that have a `Item: 'static` despite the iterator having a lifetime or the `PartialEq` implementations where the flipped one cannot elide the lifetime.
2018-12-25Remove licensesMark Rousskov-10/+0
2018-12-04cleanup: remove static lifetimes from consts in libstdljedrz-21/+21
2018-07-12make reference to dirs crate clickable in terminalsRalf Jung-1/+1
2018-07-07Deprecate `std::env::home_dir` and fix incorrect documentationSimon Ochsenreither-10/+15
2018-05-14env: remove unwrap in examples in favor of try opJohn-John Tedro-12/+21
2018-04-05Correct a few stability attributesOliver Middleton-4/+4
2018-03-28Remove hidden `foo` functions from doc examples; use `Termination` trait.Corey Farwell-7/+7
Fixes https://github.com/rust-lang/rust/issues/49233.
2018-02-05Unimplement Send/Sync for ::env::{Args,ArgsOs,Vars,VarsOs}panicbit-0/+12
2018-01-11Make tests build on CloudABI.Ed Schouten-2/+9
There are some tests that need to be disabled on CloudABI specifically, due to the fact that the shims cannot be built in combination with unix::ext or windows::ext. Also improve the scoping of some imports to suppress compiler warnings.
2017-12-24Minor rewrite of env::current_exe docs; clarify symlinks.Corey Farwell-8/+11
- Update example in ‘security’ section to use hard links, like the linked securityvulns.com example. - Weaken language on symbolic links – indicate behavior is platform-specific Fixes https://github.com/rust-lang/rust/issues/43617.
2017-11-07Warn about non-portability of glob patternsKornel-0/+4
2017-06-24Move global vars changing tests into run-passStepan Koltsov-81/+1
Should fix race #42795
2017-06-22Auto merge of #42798 - stepancheg:args-debug, r=sfacklerbors-2/+16
Better Debug for Args and ArgsOs Display actual args instead of two dots.
2017-06-21Better Debug for Args and ArgsOsStepan Koltsov-2/+16
Display actual args instead of two dots.
2017-06-20Add a couple doc additional examples for `env::join_paths`.Corey Farwell-0/+29
2017-06-12Rollup merge of #42579 - maccoda:maccoda/env_docs, r=steveklabnikCorey Farwell-9/+11
env docs completion. Should be closing #29351 with the alignment of the iterators to the template.
2017-06-10env docs completion.Dylan Maccora-9/+11
2017-05-20Rollup merge of #42091 - maccoda:maccoda/env_docs, r=frewsxcvMark Simulacrum-16/+33
Improving std::env docs Addresses #29351. Hopefully this addresses the following points: > - iterators should use the standard iterator boilerplate like https://doc.rust-lang.org/std/iter/struct.Map.html, this applies to all structs except for JoinPathsError > - JoinPathsError should properly link the function it comes from and use language similar to https://doc.rust-lang.org/std/io/struct.Error.html > - same wording issues with VarError > - functions need to ensure linkage to things they refer to in their descriptions > - Explain the difference between `os` and non-`os` structs and methods
2017-05-20Auto merge of #42111 - ollie27:stab, r=Mark-Simulacrumbors-2/+2
Correct some stability versions These were found by running tidy on stable versions of rust and finding features stabilised with the wrong version numbers.
2017-05-20Correct some stability versionsOliver Middleton-2/+2
These were found by running tidy on stable versions of rust and finding features stabilised with the wrong version numbers.
2017-05-20Merge branch 'master' into maccoda/env_docsDylan Maccora-7/+10
2017-05-20Fixed link issue.Dylan Maccora-2/+2
2017-05-18std::env docsDylan Maccora-18/+35
2017-05-18misc doc improvements for std::envTshepang Lekhonkhobe-9/+12
2017-03-05clarify docs for Args and ArgsOsJack O'Connor-0/+8
The args() and args_os() docs include a line about how the first element is usually the program name. Include that line in the struct docs too.
2017-02-18Add missing urls for env functionsGuillaume Gomez-4/+11
2017-02-08Add missing urls on join_pathsGuillaume Gomez-4/+8
2017-02-07Add missing urls for current_dirGuillaume Gomez-2/+5
2017-01-29Fix a few impl stability attributesOliver Middleton-5/+5
The versions show up in rustdoc.
2017-01-27Fix a few links in the docsOliver Middleton-1/+1
2017-01-22libstd: replace all `try!` with `?` in documentation examplesUtkarsh Kukreti-1/+1
See #38644.
2017-01-12Minor improvements to docs in std::env structures/functions.Corey Farwell-8/+12
* Call functions "functions" instead of "methods". * Link structures to their constructor functions * Add other misc. documentation links
2016-12-29libstd: define std::env::consts::ARCH for sparc64Jonathan A. Kollasch-0/+6
2016-12-18Implement `fmt::Debug` for all structures in libstd.Corey Farwell-0/+36
Part of https://github.com/rust-lang/rust/issues/31869. Also turn on the `missing_debug_implementations` lint at the crate level.
2016-12-04std: Forward ExactSizeIterator::is_empty for Args, ArgsOs iteratorsUlrik Sverdrup-0/+2
2016-11-21Add some internal docs links for Args/ArgsOsJohn Downey-5/+13