Skip to content

Commit

Permalink
Merge pull request #3492 from kornelski/trac
Browse files Browse the repository at this point in the history
More track_caller
  • Loading branch information
epage committed Feb 21, 2022
2 parents bc2be89 + 2437051 commit 006a161
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/parse/matches/arg_matches.rs
Expand Up @@ -138,6 +138,7 @@ impl ArgMatches {
/// [`ArgMatches::values_of`]: ArgMatches::values_of()
/// [`default_value`]: crate::Arg::default_value()
/// [`occurrences_of`]: crate::ArgMatches::occurrences_of()
#[cfg_attr(debug_assertions, track_caller)]
pub fn value_of<T: Key>(&self, id: T) -> Option<&str> {
let id = Id::from(id);
let arg = self.get_arg(&id)?;
Expand Down Expand Up @@ -277,6 +278,7 @@ impl ArgMatches {
/// ```
/// [values]: Values
/// [`Iterator`]: std::iter::Iterator
#[cfg_attr(debug_assertions, track_caller)]
pub fn values_of<T: Key>(&self, id: T) -> Option<Values> {
let id = Id::from(id);
let arg = self.get_arg(&id)?;
Expand All @@ -293,6 +295,7 @@ impl ArgMatches {

/// Placeholder documentation.
#[cfg(feature = "unstable-grouped")]
#[cfg_attr(debug_assertions, track_caller)]
pub fn grouped_values_of<T: Key>(&self, id: T) -> Option<GroupedValues> {
let id = Id::from(id);
let arg = self.get_arg(&id)?;
Expand Down

0 comments on commit 006a161

Please sign in to comment.