From 688ae0a58361889feedcff9eeb5ff1e1b710906b Mon Sep 17 00:00:00 2001 From: cui fliter Date: Tue, 5 Mar 2024 02:09:52 +0800 Subject: [PATCH] remove repetitive code (#53592) --- base/broadcast.jl | 2 +- stdlib/Profile/src/Allocs.jl | 2 +- stdlib/REPL/src/REPL.jl | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/base/broadcast.jl b/base/broadcast.jl index 90453ccf19aa3..d26613233a271 100644 --- a/base/broadcast.jl +++ b/base/broadcast.jl @@ -338,7 +338,7 @@ function flatten(bc::Broadcasted) # concatenate the nested arguments into {a, b, c, d} args = cat_nested(bc) # build a tuple of functions `makeargs`. Its elements take - # the whole "flat" argument list and and generate the appropriate + # the whole "flat" argument list and generate the appropriate # input arguments for the broadcasted function `f`, e.g., # makeargs[1] = ((w, x, y, z)) -> w # makeargs[2] = ((w, x, y, z)) -> g(x, y) diff --git a/stdlib/Profile/src/Allocs.jl b/stdlib/Profile/src/Allocs.jl index 59399b1f21bb3..a1cee98871011 100644 --- a/stdlib/Profile/src/Allocs.jl +++ b/stdlib/Profile/src/Allocs.jl @@ -40,7 +40,7 @@ end Profile.Allocs.@profile [sample_rate=0.1] expr Profile allocations that happen during `expr`, returning -both the result and and AllocResults struct. +both the result and AllocResults struct. A sample rate of 1.0 will record everything; 0.0 will record nothing. diff --git a/stdlib/REPL/src/REPL.jl b/stdlib/REPL/src/REPL.jl index bb5915c192b6e..f78f318d268e1 100644 --- a/stdlib/REPL/src/REPL.jl +++ b/stdlib/REPL/src/REPL.jl @@ -962,7 +962,7 @@ end find_hist_file() = get(ENV, "JULIA_HISTORY", !isempty(DEPOT_PATH) ? joinpath(DEPOT_PATH[1], "logs", "repl_history.jl") : - error("DEPOT_PATH is empty and and ENV[\"JULIA_HISTORY\"] not set.")) + error("DEPOT_PATH is empty and ENV[\"JULIA_HISTORY\"] not set.")) backend(r::AbstractREPL) = r.backendref