Loogle!
Result
Found 24 declarations mentioning Std.HashMap.map.
- Std.HashMap.map 📋 Std.Data.HashMap.AdditionalOperations
{α : Type u} {β : Type v} {γ : Type w} [BEq α] [Hashable α] (f : α → β → γ) (m : Std.HashMap α β) : Std.HashMap α γ - Std.HashMap.map_id_equiv 📋 Std.Data.HashMap.Lemmas
{α : Type u} {β : Type v} {x✝ : BEq α} {x✝¹ : Hashable α} {m : Std.HashMap α β} : (Std.HashMap.map (fun x v => v) m).Equiv m - Std.HashMap.keys_map 📋 Std.Data.HashMap.Lemmas
{α : Type u} {β : Type v} {γ : Type w} {x✝ : BEq α} {x✝¹ : Hashable α} {m : Std.HashMap α β} {f : α → β → γ} : (Std.HashMap.map f m).keys.Perm m.keys - Std.HashMap.isEmpty_map 📋 Std.Data.HashMap.Lemmas
{α : Type u} {β : Type v} {γ : Type w} {x✝ : BEq α} {x✝¹ : Hashable α} {m : Std.HashMap α β} [EquivBEq α] [LawfulHashable α] {f : α → β → γ} : (Std.HashMap.map f m).isEmpty = m.isEmpty - Std.HashMap.size_map 📋 Std.Data.HashMap.Lemmas
{α : Type u} {β : Type v} {γ : Type w} {x✝ : BEq α} {x✝¹ : Hashable α} {m : Std.HashMap α β} [EquivBEq α] [LawfulHashable α] {f : α → β → γ} : (Std.HashMap.map f m).size = m.size - Std.HashMap.contains_map 📋 Std.Data.HashMap.Lemmas
{α : Type u} {β : Type v} {γ : Type w} {x✝ : BEq α} {x✝¹ : Hashable α} {m : Std.HashMap α β} [EquivBEq α] [LawfulHashable α] {f : α → β → γ} {k : α} : (Std.HashMap.map f m).contains k = m.contains k - Std.HashMap.getKey?_map 📋 Std.Data.HashMap.Lemmas
{α : Type u} {β : Type v} {γ : Type w} {x✝ : BEq α} {x✝¹ : Hashable α} {m : Std.HashMap α β} [EquivBEq α] [LawfulHashable α] {f : α → β → γ} {k : α} : (Std.HashMap.map f m).getKey? k = m.getKey? k - Std.HashMap.Equiv.map 📋 Std.Data.HashMap.Lemmas
{α : Type u} {β : Type v} {γ : Type w} {x✝ : BEq α} {x✝¹ : Hashable α} {m₁ m₂ : Std.HashMap α β} (f : α → β → γ) (h : m₁.Equiv m₂) : (Std.HashMap.map f m₁).Equiv (Std.HashMap.map f m₂) - Std.HashMap.filterMap_equiv_map 📋 Std.Data.HashMap.Lemmas
{α : Type u} {β : Type v} {γ : Type w} {x✝ : BEq α} {x✝¹ : Hashable α} {m : Std.HashMap α β} [EquivBEq α] [LawfulHashable α] {f : α → β → γ} : (Std.HashMap.filterMap (fun k v => some (f k v)) m).Equiv (Std.HashMap.map f m) - Std.HashMap.getKeyD_map 📋 Std.Data.HashMap.Lemmas
{α : Type u} {β : Type v} {γ : Type w} {x✝ : BEq α} {x✝¹ : Hashable α} {m : Std.HashMap α β} [EquivBEq α] [LawfulHashable α] {f : α → β → γ} {k fallback : α} : (Std.HashMap.map f m).getKeyD k fallback = m.getKeyD k fallback - Std.HashMap.contains_of_contains_map 📋 Std.Data.HashMap.Lemmas
{α : Type u} {β : Type v} {γ : Type w} {x✝ : BEq α} {x✝¹ : Hashable α} {m : Std.HashMap α β} [EquivBEq α] [LawfulHashable α] {f : α → β → γ} {k : α} : (Std.HashMap.map f m).contains k = true → m.contains k = true - Std.HashMap.getKey!_map 📋 Std.Data.HashMap.Lemmas
{α : Type u} {β : Type v} {γ : Type w} {x✝ : BEq α} {x✝¹ : Hashable α} {m : Std.HashMap α β} [EquivBEq α] [LawfulHashable α] [Inhabited α] {f : α → β → γ} {k : α} : (Std.HashMap.map f m).getKey! k = m.getKey! k - Std.HashMap.map_map_equiv 📋 Std.Data.HashMap.Lemmas
{α : Type u} {β : Type v} {γ : Type w} {δ : Type w'} {x✝ : BEq α} {x✝¹ : Hashable α} {m : Std.HashMap α β} {f : α → β → γ} {g : α → γ → δ} : (Std.HashMap.map g (Std.HashMap.map f m)).Equiv (Std.HashMap.map (fun k v => g k (f k v)) m) - Std.HashMap.mem_of_mem_map 📋 Std.Data.HashMap.Lemmas
{α : Type u} {β : Type v} {γ : Type w} {x✝ : BEq α} {x✝¹ : Hashable α} {m : Std.HashMap α β} [EquivBEq α] [LawfulHashable α] {f : α → β → γ} {k : α} : k ∈ Std.HashMap.map f m → k ∈ m - Std.HashMap.mem_map 📋 Std.Data.HashMap.Lemmas
{α : Type u} {β : Type v} {γ : Type w} {x✝ : BEq α} {x✝¹ : Hashable α} {m : Std.HashMap α β} [EquivBEq α] [LawfulHashable α] {f : α → β → γ} {k : α} : k ∈ Std.HashMap.map f m ↔ k ∈ m - Std.HashMap.toList_map 📋 Std.Data.HashMap.Lemmas
{α : Type u} {β : Type v} {γ : Type w} {x✝ : BEq α} {x✝¹ : Hashable α} {m : Std.HashMap α β} {f : α → β → γ} : (Std.HashMap.map f m).toList.Perm (List.map (fun p => (p.1, f p.1 p.2)) m.toList) - Std.HashMap.getKey_map 📋 Std.Data.HashMap.Lemmas
{α : Type u} {β : Type v} {γ : Type w} {x✝ : BEq α} {x✝¹ : Hashable α} {m : Std.HashMap α β} [EquivBEq α] [LawfulHashable α] {f : α → β → γ} {k : α} {h' : k ∈ Std.HashMap.map f m} : (Std.HashMap.map f m).getKey k h' = m.getKey k ⋯ - Std.HashMap.getD_map_of_getKey?_eq_some 📋 Std.Data.HashMap.Lemmas
{α : Type u} {β : Type v} {γ : Type w} {x✝ : BEq α} {x✝¹ : Hashable α} {m : Std.HashMap α β} [EquivBEq α] [LawfulHashable α] [Inhabited γ] {f : α → β → γ} {k k' : α} {fallback : γ} (h : m.getKey? k = some k') : (Std.HashMap.map f m).getD k fallback = (Option.map (f k') m[k]?).getD fallback - Std.HashMap.getElem?_map_of_getKey?_eq_some 📋 Std.Data.HashMap.Lemmas
{α : Type u} {β : Type v} {γ : Type w} {x✝ : BEq α} {x✝¹ : Hashable α} {m : Std.HashMap α β} [EquivBEq α] [LawfulHashable α] {f : α → β → γ} {k k' : α} (h : m.getKey? k = some k') : (Std.HashMap.map f m)[k]? = Option.map (f k') m[k]? - Std.HashMap.getElem!_map_of_getKey?_eq_some 📋 Std.Data.HashMap.Lemmas
{α : Type u} {β : Type v} {γ : Type w} {x✝ : BEq α} {x✝¹ : Hashable α} {m : Std.HashMap α β} [EquivBEq α] [LawfulHashable α] [Inhabited γ] {f : α → β → γ} {k k' : α} (h : m.getKey? k = some k') : (Std.HashMap.map f m)[k]! = (Option.map (f k') m[k]?).get! - Std.HashMap.getElem_map 📋 Std.Data.HashMap.Lemmas
{α : Type u} {β : Type v} {γ : Type w} {x✝ : BEq α} {x✝¹ : Hashable α} {m : Std.HashMap α β} [EquivBEq α] [LawfulHashable α] {f : α → β → γ} {k : α} {h' : k ∈ Std.HashMap.map f m} : (Std.HashMap.map f m)[k] = f (m.getKey k ⋯) m[k] - Std.HashMap.getD_map 📋 Std.Data.HashMap.Lemmas
{α : Type u} {β : Type v} {γ : Type w} {x✝ : BEq α} {x✝¹ : Hashable α} {m : Std.HashMap α β} [EquivBEq α] [LawfulHashable α] {f : α → β → γ} {k : α} {fallback : γ} : (Std.HashMap.map f m).getD k fallback = (Option.pmap (fun v h => f (m.getKey k h) v) m[k]? ⋯).getD fallback - Std.HashMap.getElem?_map 📋 Std.Data.HashMap.Lemmas
{α : Type u} {β : Type v} {γ : Type w} {x✝ : BEq α} {x✝¹ : Hashable α} {m : Std.HashMap α β} [EquivBEq α] [LawfulHashable α] {f : α → β → γ} {k : α} : (Std.HashMap.map f m)[k]? = Option.pmap (fun v h' => f (m.getKey k h') v) m[k]? ⋯ - Std.HashMap.getElem!_map 📋 Std.Data.HashMap.Lemmas
{α : Type u} {β : Type v} {γ : Type w} {x✝ : BEq α} {x✝¹ : Hashable α} {m : Std.HashMap α β} [EquivBEq α] [LawfulHashable α] [Inhabited γ] {f : α → β → γ} {k : α} : (Std.HashMap.map f m)[k]! = (Option.pmap (fun v h => f (m.getKey k h) v) m[k]? ⋯).get!
About
Loogle searches Lean and Mathlib definitions and theorems.
You can use Loogle from within the Lean4 VSCode language extension
using (by default) Ctrl-K Ctrl-S. You can also try the
#loogle
command from LeanSearchClient,
the CLI version, the Loogle
VS Code extension, the lean.nvim
integration or the Zulip bot.
Usage
Loogle finds definitions and lemmas in various ways:
By constant:
🔍Real.sin
finds all lemmas whose statement somehow mentions the sine function.By lemma name substring:
🔍"differ"
finds all lemmas that have"differ"
somewhere in their lemma name.By subexpression:
🔍_ * (_ ^ _)
finds all lemmas whose statements somewhere include a product where the second argument is raised to some power.The pattern can also be non-linear, as in
🔍Real.sqrt ?a * Real.sqrt ?a
If the pattern has parameters, they are matched in any order. Both of these will find
List.map
:
🔍(?a -> ?b) -> List ?a -> List ?b
🔍List ?a -> (?a -> ?b) -> List ?b
By main conclusion:
🔍|- tsum _ = _ * tsum _
finds all lemmas where the conclusion (the subexpression to the right of all→
and∀
) has the given shape.As before, if the pattern has parameters, they are matched against the hypotheses of the lemma in any order; for example,
🔍|- _ < _ → tsum _ < tsum _
will findtsum_lt_tsum
even though the hypothesisf i < g i
is not the last.
If you pass more than one such search filter, separated by commas
Loogle will return lemmas which match all of them. The
search
🔍 Real.sin, "two", tsum, _ * _, _ ^ _, |- _ < _ → _
would find all lemmas which mention the constants Real.sin
and tsum
, have "two"
as a substring of the
lemma name, include a product and a power somewhere in the type,
and have a hypothesis of the form _ < _
(if
there were any such lemmas). Metavariables (?a
) are
assigned independently in each filter.
The #lucky
button will directly send you to the
documentation of the first hit.
Source code
You can find the source code for this service at https://github.com/nomeata/loogle. The https://loogle.lean-lang.org/ service is provided by the Lean FRO.
This is Loogle revision 19971e9
serving mathlib revision bce1d65