Skip to content

Commit 3972d84

Browse files
committed
Remove deprecated
1 parent 9d80649 commit 3972d84

File tree

3 files changed

+5
-53
lines changed

3 files changed

+5
-53
lines changed

CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,10 @@
11
# Changelog
22

3+
## Unreleased
4+
5+
- The deprecated `debug` function in the `io` module has been removed.
6+
- The deprecated `from` function in the `dynamic` module has been removed.
7+
38
## v0.60.0 - 2025-05-13
49

510
- The deprecated items in the `dynamic` module have been removed.

src/gleam/dynamic.gleam

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -29,11 +29,6 @@ pub type Dynamic
2929
@external(javascript, "../gleam_stdlib.mjs", "classify_dynamic")
3030
pub fn classify(data: Dynamic) -> String
3131

32-
@deprecated("Please use the other functions in the gleam/dynamic module")
33-
@external(erlang, "gleam_stdlib", "identity")
34-
@external(javascript, "../gleam_stdlib.mjs", "identity")
35-
pub fn from(a: anything) -> Dynamic
36-
3732
/// Create a dynamic value from a bool.
3833
///
3934
@external(erlang, "gleam_stdlib", "identity")

src/gleam/io.gleam

Lines changed: 0 additions & 48 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
import gleam/string
2-
31
/// Writes a string to standard output (stdout).
42
///
53
/// If you want your output to be printed on its own line see `println`.
@@ -59,49 +57,3 @@ pub fn println(string: String) -> Nil
5957
@external(erlang, "gleam_stdlib", "println_error")
6058
@external(javascript, "../gleam_stdlib.mjs", "console_error")
6159
pub fn println_error(string: String) -> Nil
62-
63-
/// Writes a value to standard error (stderr) yielding Gleam syntax.
64-
///
65-
/// The value is returned after being printed so it can be used in pipelines.
66-
///
67-
/// ## Example
68-
///
69-
/// ```gleam
70-
/// debug("Hi mum")
71-
/// // -> "Hi mum"
72-
/// // <<"Hi mum">>
73-
/// ```
74-
///
75-
/// ```gleam
76-
/// debug(Ok(1))
77-
/// // -> Ok(1)
78-
/// // {ok, 1}
79-
/// ```
80-
///
81-
/// ```gleam
82-
/// import gleam/list
83-
///
84-
/// [1, 2]
85-
/// |> list.map(fn(x) { x + 1 })
86-
/// |> debug
87-
/// |> list.map(fn(x) { x * 2 })
88-
/// // -> [4, 6]
89-
/// // [2, 3]
90-
/// ```
91-
///
92-
/// Note: At runtime Gleam doesn't have type information anymore. This combined
93-
/// with some types having the same runtime representation results in it not
94-
/// always being possible to correctly choose which Gleam syntax to show.
95-
///
96-
@deprecated("To debug print a value use the `echo` keyword instead")
97-
pub fn debug(term: anything) -> anything {
98-
term
99-
|> string.inspect
100-
|> do_debug_println
101-
102-
term
103-
}
104-
105-
@external(erlang, "gleam_stdlib", "println_error")
106-
@external(javascript, "../gleam_stdlib.mjs", "print_debug")
107-
fn do_debug_println(string string: String) -> Nil

0 commit comments

Comments
 (0)