Skip to content

Commit

Permalink
chore: reduce imports (#533)
Browse files Browse the repository at this point in the history
Co-authored-by: Mario Carneiro <[email protected]>
  • Loading branch information
kim-em and digama0 authored Jan 17, 2024
1 parent 8d34048 commit ee4a0f1
Show file tree
Hide file tree
Showing 30 changed files with 31 additions and 32 deletions.
1 change: 0 additions & 1 deletion Std/CodeAction/Basic.lean
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ Authors: Mario Carneiro
-/
import Lean.Elab.BuiltinTerm
import Lean.Elab.BuiltinNotation
import Std.Lean.Name
import Std.Lean.InfoTree
import Std.CodeAction.Attr

Expand Down
4 changes: 3 additions & 1 deletion Std/CodeAction/Misc.lean
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,11 @@ Copyright (c) 2023 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Lean.Elab.BuiltinTerm
import Lean.Elab.BuiltinNotation
import Std.Lean.Name
import Std.Lean.Position
import Std.CodeAction.Basic
import Std.CodeAction.Attr

/-!
# Miscellaneous code actions
Expand Down
2 changes: 1 addition & 1 deletion Std/Control/Nondet/Basic.lean
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ Copyright (c) 2023 Scott Morrison. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Scott Morrison
-/
import Std.Tactic.Lint
import Std.Tactic.Lint.Misc
import Std.Data.MLList.Basic

/-!
Expand Down
1 change: 1 addition & 0 deletions Std/Data/Array/Init/Lemmas.lean
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ Authors: Mario Carneiro
import Std.Tactic.NoMatch
import Std.Tactic.HaveI
import Std.Classes.LawfulMonad
import Std.Data.Fin.Init.Lemmas
import Std.Data.Nat.Init.Lemmas
import Std.Data.List.Init.Lemmas
import Std.Data.Array.Init.Basic
Expand Down
4 changes: 2 additions & 2 deletions Std/Data/Array/Match.lean
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ Copyright (c) 2023 F. G. Dorais. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: F. G. Dorais
-/
import Std.Data.Array.Basic
import Std.Data.Array.Lemmas
import Std.Data.Nat.Lemmas
import Std.Data.Array.Init.Lemmas

namespace Array

Expand Down
2 changes: 1 addition & 1 deletion Std/Data/Json.lean
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
Released under Apache 2.0 license as described in the file LICENSE.
Authors: E.W.Ayers, Wojciech Nawrocki
-/
import Std.Lean.Json
import Lean.Data.Json.FromToJson
import Lean.Syntax

/-!
Expand Down
1 change: 0 additions & 1 deletion Std/Data/List/Basic.lean
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ import Std.Classes.SetNotation
import Std.Tactic.NoMatch
import Std.Data.Option.Init.Lemmas
import Std.Data.Array.Init.Lemmas
import Std.Data.List.Init.Attach

namespace List

Expand Down
1 change: 0 additions & 1 deletion Std/Data/List/Init/Lemmas.lean
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ Copyright (c) 2014 Parikshit Khanna. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Parikshit Khanna, Jeremy Avigad, Leonardo de Moura, Floris van Doorn, Mario Carneiro
-/
import Std.Data.Fin.Init.Lemmas
import Std.Classes.SetNotation
import Std.Logic

Expand Down
3 changes: 1 addition & 2 deletions Std/Data/List/Lemmas.lean
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,7 @@ Authors: Parikshit Khanna, Jeremy Avigad, Leonardo de Moura, Floris van Doorn, M
-/
import Std.Control.ForInStep.Lemmas
import Std.Data.Bool
import Std.Data.Fin.Lemmas
import Std.Data.Nat.Lemmas
import Std.Data.Fin.Basic
import Std.Data.List.Basic
import Std.Data.Option.Lemmas
import Std.Classes.BEq
Expand Down
1 change: 1 addition & 0 deletions Std/Data/List/Perm.lean
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import Std.Tactic.Relation.Rfl
import Std.Data.List.Lemmas
import Std.Data.List.Count
import Std.Data.List.Pairwise
import Std.Data.List.Init.Attach

/-!
# List Permutations
Expand Down
1 change: 0 additions & 1 deletion Std/Data/Option/Basic.lean
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Std.Classes.SetNotation
import Std.Classes.LawfulMonad
import Std.Tactic.NoMatch

namespace Option
Expand Down
1 change: 0 additions & 1 deletion Std/Data/Prod/Lex.lean
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ Authors: Jannis Limperg
-/
import Std.Tactic.LeftRight
import Std.Tactic.RCases
import Std.Logic

namespace Prod

Expand Down
1 change: 1 addition & 0 deletions Std/Data/Range/Lemmas.lean
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import Std.Tactic.ByCases
import Std.Data.List.Lemmas
import Std.Data.List.Init.Attach

namespace Std.Range

Expand Down
2 changes: 0 additions & 2 deletions Std/Data/String/Basic.lean
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,6 @@ Copyright (c) 2022 Jannis Limperg. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Jannis Limperg, James Gallicchio, F. G. Dorais
-/

import Std.Data.Char
import Std.Data.Nat.Lemmas
import Std.Data.Array.Match

Expand Down
3 changes: 1 addition & 2 deletions Std/Lean/Json.lean
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,7 @@
Released under Apache 2.0 license as described in the file LICENSE.
Authors: E.W.Ayers, Mario Carneiro
-/

import Lean.Data.Json
import Lean.Data.Json.FromToJson
import Std.Lean.Float

open Lean
Expand Down
4 changes: 3 additions & 1 deletion Std/Lean/Meta/Basic.lean
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,9 @@ Copyright (c) 2022 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro, Jannis Limperg
-/
import Lean.Meta
import Lean.Elab.Term
import Lean.Meta.Tactic.Apply
import Lean.Meta.Tactic.Replace
import Std.Lean.LocalContext

open Lean Lean.Meta
Expand Down
7 changes: 6 additions & 1 deletion Std/Lean/Meta/Inaccessible.lean
Original file line number Diff line number Diff line change
@@ -1,4 +1,9 @@
import Lean.Meta
/-
Copyright (c) 2022 Jannis Limperg. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Jannis Limperg
-/
import Lean.Meta.InferType

open Lean Lean.Meta

Expand Down
2 changes: 1 addition & 1 deletion Std/Lean/Meta/Simp.lean
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ Copyright (c) 2022 Scott Morrison. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Scott Morrison, Gabriel Ebner, Floris van Doorn
-/
import Lean.Elab.Tactic.Simp
import Std.Tactic.OpenPrivate
import Std.Lean.Meta.DiscrTree

/-!
# Helper functions for using the simplifier.
Expand Down
2 changes: 0 additions & 2 deletions Std/Lean/Meta/UnusedNames.lean
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,6 @@ Copyright (c) 2022 Jannis Limperg. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Jannis Limperg
-/

import Lean.Meta
import Std.Data.String.Basic

open Lean Lean.Meta
Expand Down
1 change: 0 additions & 1 deletion Std/Lean/System/IO.lean
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ Released under Apache 2.0 license as described in the file LICENSE.
Authors: Scott Morrison
-/
import Std.Data.List.Lemmas
import Std.Data.MLList.Basic

/-!
# Functions for manipulating a list of tasks
Expand Down
1 change: 0 additions & 1 deletion Std/Lean/Util/EnvSearch.lean
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ Copyright (c) 2021 Shing Tak Lam. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Shing Tak Lam, Daniel Selsam, Mario Carneiro
-/
import Lean.Modifiers
import Std.Tactic.Lint.Misc

namespace Lean
Expand Down
2 changes: 1 addition & 1 deletion Std/Tactic/Case.lean
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ Copyright (c) 2023 Kyle Miller. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Kyle Miller
-/
import Lean.Elab.Tactic
import Lean.Elab.Tactic.Conv.Pattern

/-!
# Extensions to the `case` tactic
Expand Down
2 changes: 1 addition & 1 deletion Std/Tactic/FalseOrByContra.lean
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ Copyright (c) 2023 Lean FRO, LLC. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Scott Morrison
-/
import Std.Lean.Expr
import Lean.Elab.Tactic.Basic
import Std.Lean.Meta.Basic

/-!
Expand Down
3 changes: 1 addition & 2 deletions Std/Tactic/Lint/Basic.lean
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,8 @@ Copyright (c) 2020 Floris van Doorn. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Floris van Doorn, Robert Y. Lewis, Gabriel Ebner
-/

import Std.Util.TermUnsafe
import Std.Lean.NameMapAttribute

open Lean Meta

namespace Std.Tactic.Lint
Expand Down
1 change: 0 additions & 1 deletion Std/Tactic/Omega/Coeffs/IntList.lean
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import Std.Tactic.Omega.IntList
import Std.Tactic.Omega.MinNatAbs

/-!
# `Coeffs` as a wrapper for `IntList`
Expand Down
3 changes: 2 additions & 1 deletion Std/Tactic/Omega/Constraint.lean
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,10 @@ Copyright (c) 2023 Lean FRO, LLC. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Scott Morrison
-/
import Std.Classes.Order
import Std.Tactic.RCases
import Std.Tactic.NormCast
import Std.Tactic.Omega.OmegaM
import Std.Tactic.Omega.Coeffs.IntList

/-!
A `Constraint` consists of an optional lower and upper bound (inclusive),
Expand Down
3 changes: 2 additions & 1 deletion Std/Tactic/Omega/Core.lean
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@ Authors: Scott Morrison
-/
import Std.Tactic.Omega.OmegaM
import Std.Tactic.Omega.Constraint
import Std.Data.HashMap
import Std.Tactic.Omega.MinNatAbs
import Std.Data.HashMap.Basic

open Lean (HashSet)

Expand Down
2 changes: 2 additions & 0 deletions Std/Tactic/Relation/Symm.lean
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@ Copyright (c) 2022 Siddhartha Gadgil. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Siddhartha Gadgil, Mario Carneiro, Scott Morrison
-/
import Lean.Meta.Reduce
import Lean.Elab.Tactic.Location
import Std.Lean.Meta.Basic

/-!
Expand Down
1 change: 0 additions & 1 deletion Std/Tactic/SolveByElim.lean
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ Copyright (c) 2021 Scott Morrison. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Scott Morrison, David Renshaw
-/
import Std.Data.Option.Basic
import Std.Data.Sum.Basic
import Std.Tactic.LabelAttr
import Std.Tactic.Relation.Symm
Expand Down
1 change: 0 additions & 1 deletion Std/Util/ProofWanted.lean
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ Authors: David Thrane Christiansen
-/
import Lean.Elab.Exception
import Lean.Elab.Command
import Lean.Parser


open Lean Parser Elab Command
Expand Down

0 comments on commit ee4a0f1

Please sign in to comment.