Fork of daniellemaywood.uk/gleam — Wasm codegen work
2

Configure Feed

Select the types of activity you want to include in your feed.

Regenerate snapshots

+11 -377
-2
compiler-core/src/erlang/tests/snapshots/gleam_core__erlang__tests__assert__assert_binary_operation.snap
··· 1 1 --- 2 2 source: compiler-core/src/erlang/tests/assert.rs 3 - assertion_line: 28 4 3 expression: "\npub fn main() {\n let x = True\n assert x || False\n}\n" 5 - snapshot_kind: text 6 4 --- 7 5 ----- SOURCE CODE 8 6
-2
compiler-core/src/erlang/tests/snapshots/gleam_core__erlang__tests__assert__assert_binary_operator_with_side_effects.snap
··· 1 1 --- 2 2 source: compiler-core/src/erlang/tests/assert.rs 3 - assertion_line: 92 4 3 expression: "\nfn wibble(a, b) {\n let result = a + b\n result == 10\n}\n\npub fn go(x) {\n assert True && wibble(1, 4)\n}\n" 5 - snapshot_kind: text 6 4 --- 7 5 ----- SOURCE CODE 8 6
-2
compiler-core/src/erlang/tests/snapshots/gleam_core__erlang__tests__assert__assert_function_call2.snap
··· 1 1 --- 2 2 source: compiler-core/src/erlang/tests/assert.rs 3 - assertion_line: 77 4 3 expression: "\nfn and(a, b) {\n a && b\n}\n\npub fn go(x) {\n assert and(True, x)\n}\n" 5 - snapshot_kind: text 6 4 --- 7 5 ----- SOURCE CODE 8 6
-2
compiler-core/src/erlang/tests/snapshots/gleam_core__erlang__tests__assert__assert_literal.snap
··· 1 1 --- 2 2 source: compiler-core/src/erlang/tests/assert.rs 3 - assertion_line: 17 4 3 expression: "\npub fn main() {\n assert False\n}\n" 5 - snapshot_kind: text 6 4 --- 7 5 ----- SOURCE CODE 8 6
-2
compiler-core/src/erlang/tests/snapshots/gleam_core__erlang__tests__assert__assert_nested_function_call.snap
··· 1 1 --- 2 2 source: compiler-core/src/erlang/tests/assert.rs 3 - assertion_line: 92 4 3 expression: "\nfn and(x, y) {\n x && y\n}\n\npub fn main() {\n assert and(and(True, False), True)\n}\n" 5 - snapshot_kind: text 6 4 --- 7 5 ----- SOURCE CODE 8 6
-2
compiler-core/src/erlang/tests/snapshots/gleam_core__erlang__tests__assert__assert_with_block_message.snap
··· 1 1 --- 2 2 source: compiler-core/src/erlang/tests/assert.rs 3 - assertion_line: 135 4 3 expression: "\nfn identity(a) {\n a\n}\n\npub fn main() {\n assert identity(True) as {\n let message = identity(\"This shouldn't fail\")\n message\n }\n}\n" 5 - snapshot_kind: text 6 4 --- 7 5 ----- SOURCE CODE 8 6
-2
compiler-core/src/erlang/tests/snapshots/gleam_core__erlang__tests__assert__assert_with_message.snap
··· 1 1 --- 2 2 source: compiler-core/src/erlang/tests/assert.rs 3 - assertion_line: 124 4 3 expression: "\npub fn main() {\n assert True as \"This shouldn't fail\"\n}\n" 5 - snapshot_kind: text 6 4 --- 7 5 ----- SOURCE CODE 8 6
-8
compiler-core/src/error/snapshots/gleam_core__error__tests__shell_program_not_found_bun_linux_other.snap
··· 1 - --- 2 - source: compiler-core/src/error/tests.rs 3 - expression: "err[0].text" 4 - --- 5 - The program `bun` was not found. Is it installed? 6 - 7 - Documentation for installing Bun can be viewed here: 8 - https://bun.sh/docs/installation/
-8
compiler-core/src/error/snapshots/gleam_core__error__tests__shell_program_not_found_bun_linux_ubuntu.snap
··· 1 - --- 2 - source: compiler-core/src/error/tests.rs 3 - expression: "err[0].text" 4 - --- 5 - The program `bun` was not found. Is it installed? 6 - 7 - Documentation for installing Bun can be viewed here: 8 - https://bun.sh/docs/installation/
-10
compiler-core/src/error/snapshots/gleam_core__error__tests__shell_program_not_found_bun_macos_other.snap
··· 1 - --- 2 - source: compiler-core/src/error/tests.rs 3 - expression: "err[0].text" 4 - --- 5 - The program `bun` was not found. Is it installed? 6 - 7 - You can install Bun via homebrew: brew install oven-sh/bun/bun 8 - 9 - Documentation for installing Bun can be viewed here: 10 - https://bun.sh/docs/installation/
-8
compiler-core/src/error/snapshots/gleam_core__error__tests__shell_program_not_found_deno_linux_other.snap
··· 1 - --- 2 - source: compiler-core/src/error/tests.rs 3 - expression: "err[0].text" 4 - --- 5 - The program `deno` was not found. Is it installed? 6 - 7 - Documentation for installing Deno can be viewed here: 8 - https://docs.deno.com/runtime/getting_started/installation/
-8
compiler-core/src/error/snapshots/gleam_core__error__tests__shell_program_not_found_deno_linux_ubuntu.snap
··· 1 - --- 2 - source: compiler-core/src/error/tests.rs 3 - expression: "err[0].text" 4 - --- 5 - The program `deno` was not found. Is it installed? 6 - 7 - Documentation for installing Deno can be viewed here: 8 - https://docs.deno.com/runtime/getting_started/installation/
-10
compiler-core/src/error/snapshots/gleam_core__error__tests__shell_program_not_found_deno_macos_other.snap
··· 1 - --- 2 - source: compiler-core/src/error/tests.rs 3 - expression: "err[0].text" 4 - --- 5 - The program `deno` was not found. Is it installed? 6 - 7 - You can install Deno via homebrew: brew install deno 8 - 9 - Documentation for installing Deno can be viewed here: 10 - https://docs.deno.com/runtime/getting_started/installation/
-8
compiler-core/src/error/snapshots/gleam_core__error__tests__shell_program_not_found_elixir_linux_other.snap
··· 1 - --- 2 - source: compiler-core/src/error/tests.rs 3 - expression: "err[0].text" 4 - --- 5 - The program `elixir` was not found. Is it installed? 6 - 7 - Documentation for installing Elixir can be viewed here: 8 - https://elixir-lang.org/install.html
-10
compiler-core/src/error/snapshots/gleam_core__error__tests__shell_program_not_found_elixir_linux_ubuntu.snap
··· 1 - --- 2 - source: compiler-core/src/error/tests.rs 3 - expression: "err[0].text" 4 - --- 5 - The program `elixir` was not found. Is it installed? 6 - 7 - You can install Elixir via apt: sudo apt install elixir 8 - 9 - Documentation for installing Elixir can be viewed here: 10 - https://elixir-lang.org/install.html
-10
compiler-core/src/error/snapshots/gleam_core__error__tests__shell_program_not_found_elixir_macos_other.snap
··· 1 - --- 2 - source: compiler-core/src/error/tests.rs 3 - expression: "err[0].text" 4 - --- 5 - The program `elixir` was not found. Is it installed? 6 - 7 - You can install Elixir via homebrew: brew install elixir 8 - 9 - Documentation for installing Elixir can be viewed here: 10 - https://elixir-lang.org/install.html
-8
compiler-core/src/error/snapshots/gleam_core__error__tests__shell_program_not_found_erlc_linux_other.snap
··· 1 - --- 2 - source: compiler-core/src/error/tests.rs 3 - expression: "err[0].text" 4 - --- 5 - The program `erlc` was not found. Is it installed? 6 - 7 - Documentation for installing Erlang can be viewed here: 8 - https://gleam.run/getting-started/installing/
-8
compiler-core/src/error/snapshots/gleam_core__error__tests__shell_program_not_found_erlc_linux_ubuntu.snap
··· 1 - --- 2 - source: compiler-core/src/error/tests.rs 3 - expression: "err[0].text" 4 - --- 5 - The program `erlc` was not found. Is it installed? 6 - 7 - Documentation for installing Erlang can be viewed here: 8 - https://gleam.run/getting-started/installing/
-8
compiler-core/src/error/snapshots/gleam_core__error__tests__shell_program_not_found_git_linux_other.snap
··· 1 - --- 2 - source: compiler-core/src/error/tests.rs 3 - expression: "err[0].text" 4 - --- 5 - The program `git` was not found. Is it installed? 6 - 7 - Documentation for installing Git can be viewed here: 8 - https://git-scm.com/book/en/v2/Getting-Started-Installing-Git
-10
compiler-core/src/error/snapshots/gleam_core__error__tests__shell_program_not_found_git_linux_ubuntu.snap
··· 1 - --- 2 - source: compiler-core/src/error/tests.rs 3 - expression: "err[0].text" 4 - --- 5 - The program `git` was not found. Is it installed? 6 - 7 - You can install Git via apt: sudo apt install git 8 - 9 - Documentation for installing Git can be viewed here: 10 - https://git-scm.com/book/en/v2/Getting-Started-Installing-Git
-10
compiler-core/src/error/snapshots/gleam_core__error__tests__shell_program_not_found_git_macos_other.snap
··· 1 - --- 2 - source: compiler-core/src/error/tests.rs 3 - expression: "err[0].text" 4 - --- 5 - The program `git` was not found. Is it installed? 6 - 7 - You can install Git via homebrew: brew install git 8 - 9 - Documentation for installing Git can be viewed here: 10 - https://git-scm.com/book/en/v2/Getting-Started-Installing-Git
-8
compiler-core/src/error/snapshots/gleam_core__error__tests__shell_program_not_found_node_linux_other.snap
··· 1 - --- 2 - source: compiler-core/src/error/tests.rs 3 - expression: "err[0].text" 4 - --- 5 - The program `node` was not found. Is it installed? 6 - 7 - Documentation for installing Node.js via package manager can be viewed here: 8 - https://nodejs.org/en/download/package-manager/all/
-8
compiler-core/src/error/snapshots/gleam_core__error__tests__shell_program_not_found_node_linux_ubuntu.snap
··· 1 - --- 2 - source: compiler-core/src/error/tests.rs 3 - expression: "err[0].text" 4 - --- 5 - The program `node` was not found. Is it installed? 6 - 7 - Documentation for installing Node.js via package manager can be viewed here: 8 - https://nodejs.org/en/download/package-manager/all/
-10
compiler-core/src/error/snapshots/gleam_core__error__tests__shell_program_not_found_node_macos_other.snap
··· 1 - --- 2 - source: compiler-core/src/error/tests.rs 3 - expression: "err[0].text" 4 - --- 5 - The program `node` was not found. Is it installed? 6 - 7 - You can install Node.js via homebrew: brew install node 8 - 9 - Documentation for installing Node.js via package manager can be viewed here: 10 - https://nodejs.org/en/download/package-manager/all/
-8
compiler-core/src/error/snapshots/gleam_core__error__tests__shell_program_not_found_rebar3_linux_other.snap
··· 1 - --- 2 - source: compiler-core/src/error/tests.rs 3 - expression: "err[0].text" 4 - --- 5 - The program `rebar3` was not found. Is it installed? 6 - 7 - Documentation for installing Rebar3 can be viewed here: 8 - https://rebar3.org/docs/getting-started/
-8
compiler-core/src/error/snapshots/gleam_core__error__tests__shell_program_not_found_rebar3_linux_ubuntu.snap
··· 1 - --- 2 - source: compiler-core/src/error/tests.rs 3 - expression: "err[0].text" 4 - --- 5 - The program `rebar3` was not found. Is it installed? 6 - 7 - Documentation for installing Rebar3 can be viewed here: 8 - https://rebar3.org/docs/getting-started/
-10
compiler-core/src/error/snapshots/gleam_core__error__tests__shell_program_not_found_rebar3_macos_other.snap
··· 1 - --- 2 - source: compiler-core/src/error/tests.rs 3 - expression: "err[0].text" 4 - --- 5 - The program `rebar3` was not found. Is it installed? 6 - 7 - You can install Rebar3 via homebrew: brew install rebar3 8 - 9 - Documentation for installing Rebar3 can be viewed here: 10 - https://rebar3.org/docs/getting-started/
-2
compiler-core/src/javascript/tests/snapshots/gleam_core__javascript__tests__assert__assert_binary_operation.snap
··· 1 1 --- 2 2 source: compiler-core/src/javascript/tests/assert.rs 3 - assertion_line: 28 4 3 expression: "\npub fn main() {\n let x = True\n assert x || False\n}\n" 5 - snapshot_kind: text 6 4 --- 7 5 ----- SOURCE CODE 8 6
-2
compiler-core/src/javascript/tests/snapshots/gleam_core__javascript__tests__assert__assert_binary_operator_with_side_effects.snap
··· 1 1 --- 2 2 source: compiler-core/src/javascript/tests/assert.rs 3 - assertion_line: 92 4 3 expression: "\nfn wibble(a, b) {\n let result = a + b\n result == 10\n}\n\npub fn go(x) {\n assert True && wibble(1, 4)\n}\n" 5 - snapshot_kind: text 6 4 --- 7 5 ----- SOURCE CODE 8 6
-2
compiler-core/src/javascript/tests/snapshots/gleam_core__javascript__tests__assert__assert_function_call2.snap
··· 1 1 --- 2 2 source: compiler-core/src/javascript/tests/assert.rs 3 - assertion_line: 77 4 3 expression: "\nfn and(a, b) {\n a && b\n}\n\npub fn go(x) {\n assert and(True, x)\n}\n" 5 - snapshot_kind: text 6 4 --- 7 5 ----- SOURCE CODE 8 6
-2
compiler-core/src/javascript/tests/snapshots/gleam_core__javascript__tests__assert__assert_literal.snap
··· 1 1 --- 2 2 source: compiler-core/src/javascript/tests/assert.rs 3 - assertion_line: 17 4 3 expression: "\npub fn main() {\n assert False\n}\n" 5 - snapshot_kind: text 6 4 --- 7 5 ----- SOURCE CODE 8 6
-2
compiler-core/src/javascript/tests/snapshots/gleam_core__javascript__tests__assert__assert_nested_function_call.snap
··· 1 1 --- 2 2 source: compiler-core/src/javascript/tests/assert.rs 3 - assertion_line: 92 4 3 expression: "\nfn and(x, y) {\n x && y\n}\n\npub fn main() {\n assert and(and(True, False), True)\n}\n" 5 - snapshot_kind: text 6 4 --- 7 5 ----- SOURCE CODE 8 6
-2
compiler-core/src/javascript/tests/snapshots/gleam_core__javascript__tests__assert__assert_with_block_message.snap
··· 1 1 --- 2 2 source: compiler-core/src/javascript/tests/assert.rs 3 - assertion_line: 135 4 3 expression: "\nfn identity(a) {\n a\n}\n\npub fn main() {\n assert identity(True) as {\n let message = identity(\"This shouldn't fail\")\n message\n }\n}\n" 5 - snapshot_kind: text 6 4 --- 7 5 ----- SOURCE CODE 8 6
-2
compiler-core/src/javascript/tests/snapshots/gleam_core__javascript__tests__assert__assert_with_message.snap
··· 1 1 --- 2 2 source: compiler-core/src/javascript/tests/assert.rs 3 - assertion_line: 124 4 3 expression: "\npub fn main() {\n assert True as \"This shouldn't fail\"\n}\n" 5 - snapshot_kind: text 6 4 --- 7 5 ----- SOURCE CODE 8 6
-2
compiler-core/src/javascript/tests/snapshots/gleam_core__javascript__tests__bit_arrays__match_float_16_bit.snap
··· 1 1 --- 2 2 source: compiler-core/src/javascript/tests/bit_arrays.rs 3 - assertion_line: 791 4 3 expression: "\nfn go(x) {\n let assert <<a:float-size(16)>> = x\n}\n" 5 - snapshot_kind: text 6 4 --- 7 5 ----- SOURCE CODE 8 6
-2
compiler-core/src/language_server/tests/snapshots/gleam_core__language_server__tests__action__assign_unused_result.snap
··· 1 1 --- 2 2 source: compiler-core/src/language_server/tests/action.rs 3 - assertion_line: 1506 4 3 expression: "\npub fn main() {\n let x = 1\n Ok(x)\n Nil\n}\n" 5 - snapshot_kind: text 6 4 --- 7 5 ----- BEFORE ACTION 8 6
-2
compiler-core/src/language_server/tests/snapshots/gleam_core__language_server__tests__action__assign_unused_result_in_block.snap
··· 1 1 --- 2 2 source: compiler-core/src/language_server/tests/action.rs 3 - assertion_line: 1521 4 3 expression: "\npub fn main() {\n {\n let x = 1\n Ok(x)\n Nil\n }\n Nil\n}\n" 5 - snapshot_kind: text 6 4 --- 7 5 ----- BEFORE ACTION 8 6
-2
compiler-core/src/language_server/tests/snapshots/gleam_core__language_server__tests__action__assign_unused_result_on_block_end.snap
··· 1 1 --- 2 2 source: compiler-core/src/language_server/tests/action.rs 3 - assertion_line: 1557 4 3 expression: "\npub fn main() {\n {\n let x = 1\n Ok(x)\n Ok(x)\n }\n Nil\n}\n" 5 - snapshot_kind: text 6 4 --- 7 5 ----- BEFORE ACTION 8 6
-2
compiler-core/src/language_server/tests/snapshots/gleam_core__language_server__tests__action__assign_unused_result_on_block_start.snap
··· 1 1 --- 2 2 source: compiler-core/src/language_server/tests/action.rs 3 - assertion_line: 1539 4 3 expression: "\npub fn main() {\n {\n let x = 1\n Ok(x)\n Ok(x)\n }\n Nil\n}\n" 5 - snapshot_kind: text 6 4 --- 7 5 ----- BEFORE ACTION 8 6
-2
compiler-core/src/language_server/tests/snapshots/gleam_core__language_server__tests__action__assign_unused_result_only_first_action.snap
··· 1 1 --- 2 2 source: compiler-core/src/language_server/tests/action.rs 3 - assertion_line: 1593 4 3 expression: "\npub fn main() {\n let x = 1\n Ok(x)\n Ok(x)\n Nil\n}\n" 5 - snapshot_kind: text 6 4 --- 7 5 ----- BEFORE ACTION 8 6
-2
compiler-core/src/language_server/tests/snapshots/gleam_core__language_server__tests__action__extract_constant_from_declaration_of_nested_inside.snap
··· 1 1 --- 2 2 source: compiler-core/src/language_server/tests/action.rs 3 - assertion_line: 4366 4 3 expression: "pub fn main() {\n let c = #([1, 2, 3], [3, 2, 1])\n}" 5 - snapshot_kind: text 6 4 --- 7 5 ----- BEFORE ACTION 8 6 pub fn main() {
+1 -1
compiler-core/src/language_server/tests/snapshots/gleam_core__language_server__tests__action__extract_constant_from_record_variant_1.snap
··· 1 1 --- 2 2 source: compiler-core/src/language_server/tests/action.rs 3 - expression: "pub type Auth {\n Verified(String)\n Unverified\n}\n\npub fn main() {\n let u = Verified(\"User\")\n let v = verify(something, u)\n\n v\n}\n" 3 + expression: "pub type Auth {\n Verified(String)\n Unverified\n}\n\npub fn main() {\n let u = Verified(\"User\")\n let v = verify(something, u)\n\n v\n}" 4 4 --- 5 5 ----- BEFORE ACTION 6 6 pub type Auth {
+1 -1
compiler-core/src/language_server/tests/snapshots/gleam_core__language_server__tests__action__extract_constant_from_record_variant_2.snap
··· 1 1 --- 2 2 source: compiler-core/src/language_server/tests/action.rs 3 - expression: "pub type Auth {\n Verified(Int)\n Unverified\n}\n\nconst auth = True\n\nconst id = 1234\n\npub fn main() {\n let v = verify(auth, Verified(id))\n\n v\n}\n" 3 + expression: "pub type Auth {\n Verified(Int)\n Unverified\n}\n\nconst auth = True\n\nconst id = 1234\n\npub fn main() {\n let v = verify(auth, Verified(id))\n\n v\n}" 4 4 --- 5 5 ----- BEFORE ACTION 6 6 pub type Auth {
+1 -1
compiler-core/src/language_server/tests/snapshots/gleam_core__language_server__tests__action__extract_constant_from_whole_declaration_of_bin_op.snap
··· 1 1 --- 2 2 source: compiler-core/src/language_server/tests/action.rs 3 - expression: "pub fn main() {\n let twelve = \"1\" <> \"2\"\n}" 3 + expression: "import gleam/io\n\npub fn main() {\n let twelve = \"1\" <> \"2\"\n io.print(twelve)\n}" 4 4 --- 5 5 ----- BEFORE ACTION 6 6 import gleam/io
+1 -1
compiler-core/src/language_server/tests/snapshots/gleam_core__language_server__tests__action__extract_constant_from_whole_declaration_of_bit_array.snap
··· 1 1 --- 2 2 source: compiler-core/src/language_server/tests/action.rs 3 - expression: "import gleam/io\n\npub fn main() {\n let b = <<1234:unit(4)-size(32)>>\n io.debug(b)\n}" 3 + expression: "import gleam/io\n\nconst n = 24\n\npub fn main() {\n let bits = <<8080:size(n)>>\n bits\n}" 4 4 --- 5 5 ----- BEFORE ACTION 6 6 import gleam/io
+1 -1
compiler-core/src/language_server/tests/snapshots/gleam_core__language_server__tests__action__extract_constant_from_whole_declaration_of_float.snap
··· 1 1 --- 2 2 source: compiler-core/src/language_server/tests/action.rs 3 - expression: "import gleam/io\npub fn main() {\n let c = 3.1415\n io.debug(c)\n}" 3 + expression: "import gleam/io\n\npub fn main() {\n let c = 3.1415\n io.debug(c)\n}" 4 4 --- 5 5 ----- BEFORE ACTION 6 6 import gleam/io
+1 -1
compiler-core/src/language_server/tests/snapshots/gleam_core__language_server__tests__action__extract_constant_from_whole_declaration_of_int.snap
··· 1 1 --- 2 2 source: compiler-core/src/language_server/tests/action.rs 3 - expression: "import gleam/io\npub fn main() {\n let c = 125\n io.debug(c)\n}" 3 + expression: "import gleam/io\n\npub fn main() {\n let c = 125\n io.debug(c)\n}" 4 4 --- 5 5 ----- BEFORE ACTION 6 6 import gleam/io
+1 -1
compiler-core/src/language_server/tests/snapshots/gleam_core__language_server__tests__action__extract_constant_from_whole_declaration_of_list.snap
··· 1 1 --- 2 2 source: compiler-core/src/language_server/tests/action.rs 3 - expression: "import gleam/io\npub fn main() {\n let c = [3.1415, 0.33333333]\n io.debug(c)\n}" 3 + expression: "import gleam/io\n\npub fn main() {\n let c = [3.1415, 0.33333333]\n io.debug(c)\n}" 4 4 --- 5 5 ----- BEFORE ACTION 6 6 import gleam/io
+1 -1
compiler-core/src/language_server/tests/snapshots/gleam_core__language_server__tests__action__extract_constant_from_whole_declaration_of_nested.snap
··· 1 1 --- 2 2 source: compiler-core/src/language_server/tests/action.rs 3 - expression: "import gleam/io\npub fn main() {\n let c = #([1, 2, 3], [3, 2, 1])\n io.debug(c)\n}" 3 + expression: "import gleam/io\n\npub fn main() {\n let c = #([1, 2, 3], [3, 2, 1])\n io.debug(c)\n}" 4 4 --- 5 5 ----- BEFORE ACTION 6 6 import gleam/io
+1 -1
compiler-core/src/language_server/tests/snapshots/gleam_core__language_server__tests__action__extract_constant_from_whole_declaration_of_string.snap
··· 1 1 --- 2 2 source: compiler-core/src/language_server/tests/action.rs 3 - expression: "import gleam/io\npub fn main() {\n let c = \"constant\"\n io.debug(c)\n}" 3 + expression: "import gleam/io\n\npub fn main() {\n let c = \"constant\"\n io.debug(c)\n}" 4 4 --- 5 5 ----- BEFORE ACTION 6 6 import gleam/io
+1 -1
compiler-core/src/language_server/tests/snapshots/gleam_core__language_server__tests__action__extract_constant_from_whole_declaration_of_tuple.snap
··· 1 1 --- 2 2 source: compiler-core/src/language_server/tests/action.rs 3 - expression: "import gleam/io\npub fn main() {\n let c = #(\"one\", \"two\", \"three\")\n io.debug(c)\n}" 3 + expression: "import gleam/io\n\npub fn main() {\n let c = #(\"one\", \"two\", \"three\")\n io.debug(c)\n}" 4 4 --- 5 5 ----- BEFORE ACTION 6 6 import gleam/io
-2
compiler-core/src/language_server/tests/snapshots/gleam_core__language_server__tests__action__extract_constant_in_correct_position_3.snap
··· 1 1 --- 2 2 source: compiler-core/src/language_server/tests/action.rs 3 - assertion_line: 4596 4 3 expression: "\nfn first() {\n 1\n}\n\nfn second() {\n 2\n}\n\nfn third() {\n 3\n}\n" 5 - snapshot_kind: text 6 4 --- 7 5 ----- BEFORE ACTION 8 6
-2
compiler-core/src/language_server/tests/snapshots/gleam_core__language_server__tests__action__generate_json_encoder.snap
··· 1 1 --- 2 2 source: compiler-core/src/language_server/tests/action.rs 3 - assertion_line: 6421 4 3 expression: "\npub type Person {\n Person(name: String, age: Int, height: Float, is_cool: Bool)\n}\n" 5 - snapshot_kind: text 6 4 --- 7 5 ----- BEFORE ACTION 8 6
-2
compiler-core/src/language_server/tests/snapshots/gleam_core__language_server__tests__action__generate_json_encoder_already_imported_module.snap
··· 1 1 --- 2 2 source: compiler-core/src/language_server/tests/action.rs 3 - assertion_line: 6500 4 3 expression: "\nimport gleam/json as json_encoding\n\npub type Wibble {\n Wibble(a: Int, b: Float, c: String)\n}\n" 5 - snapshot_kind: text 6 4 --- 7 5 ----- BEFORE ACTION 8 6
-2
compiler-core/src/language_server/tests/snapshots/gleam_core__language_server__tests__action__generate_json_encoder_complex_types.snap
··· 1 1 --- 2 2 source: compiler-core/src/language_server/tests/action.rs 3 - assertion_line: 6465 4 3 expression: "\nimport gleam/option\nimport gleam/dict\n\npub type Something\n\npub type Wibble(value) {\n Wibble(\n maybe: option.Option(Int),\n something: Something,\n map: dict.Dict(String, List(Float)),\n unknown: List(value),\n )\n}\n" 5 - snapshot_kind: text 6 4 --- 7 5 ----- BEFORE ACTION 8 6
-2
compiler-core/src/language_server/tests/snapshots/gleam_core__language_server__tests__action__generate_json_encoder_for_multi_variant_type.snap
··· 1 1 --- 2 2 source: compiler-core/src/language_server/tests/action.rs 3 - assertion_line: 6682 4 3 expression: "\npub type Wibble {\n Wibble(wibble: Int, next: Wibble)\n Wobble(wobble: Float, text: String, values: List(Bool))\n}\n" 5 - snapshot_kind: text 6 4 --- 7 5 ----- BEFORE ACTION 8 6
-2
compiler-core/src/language_server/tests/snapshots/gleam_core__language_server__tests__action__generate_json_encoder_for_multi_variant_type_multi_word_name.snap
··· 1 1 --- 2 2 source: compiler-core/src/language_server/tests/action.rs 3 - assertion_line: 6703 4 3 expression: "\npub type Wibble {\n OneTwoThree(wibble: Int, next: Wibble)\n FourFive(wobble: Float, text: String, values: List(Bool))\n SixSevenEight(one_two: Float)\n}\n" 5 - snapshot_kind: text 6 4 --- 7 5 ----- BEFORE ACTION 8 6
-2
compiler-core/src/language_server/tests/snapshots/gleam_core__language_server__tests__action__generate_json_encoder_for_type_with_multiple_variants_with_no_fields.snap
··· 1 1 --- 2 2 source: compiler-core/src/language_server/tests/action.rs 3 - assertion_line: 6572 4 3 expression: "\npub type Wibble {\n Wibble\n Wobble\n Woo\n}\n" 5 - snapshot_kind: text 6 4 --- 7 5 ----- BEFORE ACTION 8 6
-2
compiler-core/src/language_server/tests/snapshots/gleam_core__language_server__tests__action__generate_json_encoder_for_variant_with_no_fields.snap
··· 1 1 --- 2 2 source: compiler-core/src/language_server/tests/action.rs 3 - assertion_line: 6551 4 3 expression: "\npub type Wibble {\n Wibble\n}\n" 5 - snapshot_kind: text 6 4 --- 7 5 ----- BEFORE ACTION 8 6
-2
compiler-core/src/language_server/tests/snapshots/gleam_core__language_server__tests__action__generate_json_encoder_for_variants_with_mixed_fields.snap
··· 1 1 --- 2 2 source: compiler-core/src/language_server/tests/action.rs 3 - assertion_line: 6592 4 3 expression: "\npub type Wibble {\n Wibble\n Wobble(field: String, field1: Int)\n}\n" 5 - snapshot_kind: text 6 4 --- 7 5 ----- BEFORE ACTION 8 6
-2
compiler-core/src/language_server/tests/snapshots/gleam_core__language_server__tests__action__generate_json_encoder_list_of_tuples.snap
··· 1 1 --- 2 2 source: compiler-core/src/language_server/tests/action.rs 3 - assertion_line: 6662 4 3 expression: "\npub type Wibble {\n Wibble(values: List(#(Int, String)))\n}\n" 5 - snapshot_kind: text 6 4 --- 7 5 ----- BEFORE ACTION 8 6
-2
compiler-core/src/language_server/tests/snapshots/gleam_core__language_server__tests__action__generate_json_encoder_recursive_type.snap
··· 1 1 --- 2 2 source: compiler-core/src/language_server/tests/action.rs 3 - assertion_line: 6629 4 3 expression: "\nimport gleam/option.{Some}\n\npub type LinkedList {\n LinkedList(value: Int, next: option.Option(LinkedList))\n}\n" 5 - snapshot_kind: text 6 4 --- 7 5 ----- BEFORE ACTION 8 6
-2
compiler-core/src/language_server/tests/snapshots/gleam_core__language_server__tests__action__generate_json_encoder_tuple.snap
··· 1 1 --- 2 2 source: compiler-core/src/language_server/tests/action.rs 3 - assertion_line: 6532 4 3 expression: "\npub type Wibble {\n Wibble(tuple: #(Int, Float, #(String, Bool)))\n}\n" 5 - snapshot_kind: text 6 4 --- 7 5 ----- BEFORE ACTION 8 6
-15
compiler-core/src/language_server/tests/snapshots/gleam_core__language_server__tests__action__remove_echo_removes_closest_one.snap
··· 1 - --- 2 - source: compiler-core/src/language_server/tests/action.rs 3 - expression: "pub fn main() {\n echo wibble(echo 1, 2)\n}" 4 - --- 5 - ----- BEFORE ACTION 6 - pub fn main() { 7 - echo wibble(echo 1, 2) 8 - 9 - } 10 - 11 - 12 - ----- AFTER ACTION 13 - pub fn main() { 14 - echo wibble(1, 2) 15 - }
+1 -1
compiler-core/src/language_server/tests/snapshots/gleam_core__language_server__tests__action__wrap_nested_case_clause_in_block.snap
··· 1 1 --- 2 2 source: compiler-core/src/language_server/tests/action.rs 3 - expression: "\npub fn f(result) {\n case result {\n Ok(reresult) -> {\n case reresult {\n Ok(w) -> w\n Error(_) -> panic\n }\n }\n Error(_) -> panic\n }\n}" 3 + expression: "\npub fn f(result) {\n case result {\n Ok(reresult) -> {\n case reresult {\n Ok(w) -> w\n Error(_) -> panic\n }\n }\n Error(_) -> panic\n }\n}" 4 4 --- 5 5 ----- BEFORE ACTION 6 6
-2
compiler-core/src/language_server/tests/snapshots/gleam_core__language_server__tests__reference__references_for_aliased_const.snap
··· 1 1 --- 2 2 source: compiler-core/src/language_server/tests/reference.rs 3 - assertion_line: 549 4 3 expression: "\npub const wibble = 123\n\npub fn main() {\n wibble\n}\n" 5 - snapshot_kind: text 6 4 --- 7 5 -- mod.gleam 8 6
-2
compiler-core/src/language_server/tests/snapshots/gleam_core__language_server__tests__reference__references_for_aliased_function.snap
··· 1 1 --- 2 2 source: compiler-core/src/language_server/tests/reference.rs 3 - assertion_line: 573 4 3 expression: "\npub fn wibble() {\n 123\n}\n\npub fn main() {\n wibble()\n}\n" 5 - snapshot_kind: text 6 4 --- 7 5 -- mod.gleam 8 6
-2
compiler-core/src/type_/tests/snapshots/gleam_core__type___tests__assert__bool_literal.snap
··· 1 1 --- 2 2 source: compiler-core/src/type_/tests/assert.rs 3 - assertion_line: 54 4 3 expression: "\npub fn main() {\n assert True\n}\n" 5 - snapshot_kind: text 6 4 --- 7 5 ----- SOURCE CODE 8 6
-2
compiler-core/src/type_/tests/snapshots/gleam_core__type___tests__assert__comparison_on_literals.snap
··· 1 1 --- 2 2 source: compiler-core/src/type_/tests/assert.rs 3 - assertion_line: 87 4 3 expression: "\npub fn main() {\n assert 1 < 2\n}\n" 5 - snapshot_kind: text 6 4 --- 7 5 ----- SOURCE CODE 8 6
-2
compiler-core/src/type_/tests/snapshots/gleam_core__type___tests__assert__equality_check_on_literals.snap
··· 1 1 --- 2 2 source: compiler-core/src/type_/tests/assert.rs 3 - assertion_line: 76 4 3 expression: "\npub fn main() {\n assert 1 == 2\n}\n" 5 - snapshot_kind: text 6 4 --- 7 5 ----- SOURCE CODE 8 6
-2
compiler-core/src/type_/tests/snapshots/gleam_core__type___tests__assert__negation_of_bool_literal.snap
··· 1 1 --- 2 2 source: compiler-core/src/type_/tests/assert.rs 3 - assertion_line: 65 4 3 expression: "\npub fn main() {\n assert !False\n}\n" 5 - snapshot_kind: text 6 4 --- 7 5 ----- SOURCE CODE 8 6
-21
compiler-core/src/type_/tests/snapshots/gleam_core__type___tests__assert__non_string_message.snap
··· 1 - --- 2 - source: compiler-core/src/type_/tests/assert.rs 3 - expression: let assert 1 = 2 as 3 4 - --- 5 - ----- SOURCE CODE 6 - let assert 1 = 2 as 3 7 - 8 - ----- ERROR 9 - error: Type mismatch 10 - ┌─ /src/one/two.gleam:1:21 11 - 12 - 1 │ let assert 1 = 2 as 3 13 - │ ^ 14 - 15 - Expected type: 16 - 17 - String 18 - 19 - Found type: 20 - 21 - Int
-21
compiler-core/src/type_/tests/snapshots/gleam_core__type___tests__errors__bit_array.snap
··· 1 - --- 2 - source: compiler-core/src/type_/tests/errors.rs 3 - expression: "case <<1>> { <<2.0, a>> -> 1 _ -> 2 }" 4 - --- 5 - ----- SOURCE CODE 6 - case <<1>> { <<2.0, a>> -> 1 _ -> 2 } 7 - 8 - ----- ERROR 9 - error: Type mismatch 10 - ┌─ /src/one/two.gleam:1:16 11 - 12 - 1 │ case <<1>> { <<2.0, a>> -> 1 _ -> 2 } 13 - │ ^^^ 14 - 15 - Expected type: 16 - 17 - Int 18 - 19 - Found type: 20 - 21 - Float
-25
compiler-core/src/type_/tests/snapshots/gleam_core__type___tests__exhaustiveness__bit_array_overlapping_patterns_are_redundant_2.snap
··· 1 - --- 2 - source: compiler-core/src/type_/tests/exhaustiveness.rs 3 - expression: "pub fn main() {\n let bit_array = <<>>\n case bit_array {\n <<1, a:size(16)>> -> a\n <<1, b:size(8)-unit(2)>> -> b\n _ -> 2\n }\n}" 4 - --- 5 - ----- SOURCE CODE 6 - pub fn main() { 7 - let bit_array = <<>> 8 - case bit_array { 9 - <<1, a:size(16)>> -> a 10 - <<1, b:size(8)-unit(2)>> -> b 11 - _ -> 2 12 - } 13 - } 14 - 15 - ----- WARNING 16 - warning: Unreachable case clause 17 - ┌─ /src/warning/wrn.gleam:5:5 18 - 19 - 5 │ <<1, b:size(8)-unit(2)>> -> b 20 - │ ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 21 - 22 - This case clause cannot be reached as a previous clause matches the same 23 - values. 24 - 25 - Hint: It can be safely removed.
-2
compiler-core/src/type_/tests/snapshots/gleam_core__type___tests__warnings__assert_on_inferred_variant.snap
··· 1 1 --- 2 2 source: compiler-core/src/type_/tests/warnings.rs 3 - assertion_line: 3020 4 3 expression: "\ntype Wibble {\n Wibble(w: Int)\n Wobble(w: String)\n}\n\npub fn main() {\n let assert Wobble(w) = Wibble(10)\n w\n}\n" 5 - snapshot_kind: text 6 4 --- 7 5 ----- SOURCE CODE 8 6
-24
compiler-core/src/type_/tests/snapshots/gleam_core__type___tests__warnings__bool_assert_requires_v1_10.snap
··· 1 - --- 2 - source: compiler-core/src/type_/tests/warnings.rs 3 - expression: "\npub fn go(x) {\n assert x == 2\n}\n" 4 - --- 5 - ----- SOURCE CODE 6 - 7 - pub fn go(x) { 8 - assert x == 2 9 - } 10 - 11 - 12 - ----- WARNING 13 - warning: Incompatible gleam version range 14 - ┌─ /src/warning/wrn.gleam:3:3 15 - 16 - 3 │ assert x == 2 17 - │ ^^^^^^^^^^^^^ This requires a Gleam version >= 1.11.0 18 - 19 - The bool `assert` statement was introduced in version v1.11.0. But the 20 - Gleam version range specified in your `gleam.toml` would allow this code to 21 - run on an earlier version like v1.0.0, resulting in compilation errors! 22 - Hint: Remove the version constraint from your `gleam.toml` or update it to be: 23 - 24 - gleam = ">= 1.11.0"
-2
compiler-core/src/type_/tests/snapshots/gleam_core__type___tests__warnings__unreachable_function_call_if_panic_is_last_argument_1.snap
··· 1 1 --- 2 2 source: compiler-core/src/type_/tests/warnings.rs 3 - assertion_line: 1724 4 3 expression: "\n pub fn wibble(_, _) { 1 }\n pub fn main() {\n wibble(1, panic)\n 1\n }" 5 - snapshot_kind: text 6 4 --- 7 5 ----- SOURCE CODE 8 6
-2
compiler-core/src/type_/tests/snapshots/gleam_core__type___tests__warnings__unused_record_constructor_raises_a_warning.snap
··· 1 1 --- 2 2 source: compiler-core/src/type_/tests/warnings.rs 3 - assertion_line: 1218 4 3 expression: "\npub type Thing {\n Thing(value: Int)\n}\n\npub fn main() {\n Thing(1)\n 1\n}\n" 5 - snapshot_kind: text 6 4 --- 7 5 ----- SOURCE CODE 8 6