@@ -850,6 +850,71 @@ defmodule Greeter do
850850 end
851851end" )
852852
853+ (elixir-def-indentation-test indent-binary-sequence
854+ (:tags '(indentation))
855+ "
856+ defmodule ExampleTest do
857+ test \" the truth\" do
858+ assert <<1,2>> == <<1,2>>
859+ assert 1 + 1 == 2
860+ end
861+ end"
862+
863+ "
864+ defmodule ExampleTest do
865+ test \" the truth\" do
866+ assert <<1,2>> == <<1,2>>
867+ assert 1 + 1 == 2
868+ end
869+ end" )
870+
871+ (elixir-def-indentation-test indent-binary-sequence-inside-match-block/2
872+ (:expected-result :failed :tags '(indentation))
873+ "
874+ case asd do
875+ <<c1::5, c2::5, c3::5, c4::5, c5::5, c6::5, c7::2>> ->
876+ <<main::binary,
877+ enc.(c1)::8, enc.(c2)::8, enc.(c3)::8, enc.(c4)::8,
878+ enc.(c5)::8, enc.(c6)::8, enc.(bsl(c7, 3))::8, ?=>>
879+ <<c1::5, c2::5, c3::5, c4::5, c5::4>> ->
880+ <<main::binary,
881+ enc.(c1)::8, enc.(c2)::8, enc.(c3)::8, enc.(c4)::8,
882+ enc.(bsl(c5, 1))::8, ?=, ?=, ?=>>
883+ <<c1::5, c2::5, c3::5, c4::1>> ->
884+ <<main::binary,
885+ enc.(c1)::8, enc.(c2)::8, enc.(c3)::8, enc.(bsl(c4, 4))::8,
886+ ?=, ?=, ?=, ?=>>
887+ <<c1::5, c2::3>> ->
888+ <<main::binary,
889+ enc.(c1)::8, enc.(bsl(c2, 2))::8, ?=, ?=,
890+ ?=, ?=, ?=, ?=>>
891+ <<>> ->
892+ main
893+ end"
894+
895+ "
896+ case asd do
897+ <<c1::5, c2::5, c3::5, c4::5, c5::5, c6::5, c7::2>> ->
898+ <<main::binary,
899+ enc.(c1)::8, enc.(c2)::8, enc.(c3)::8, enc.(c4)::8,
900+ enc.(c5)::8, enc.(c6)::8, enc.(bsl(c7, 3))::8, ?=>>
901+ <<c1::5, c2::5, c3::5, c4::5, c5::4>> ->
902+ <<main::binary,
903+ enc.(c1)::8, enc.(c2)::8, enc.(c3)::8, enc.(c4)::8,
904+ enc.(bsl(c5, 1))::8, ?=, ?=, ?=>>
905+ <<c1::5, c2::5, c3::5, c4::1>> ->
906+ <<main::binary,
907+ enc.(c1)::8, enc.(c2)::8, enc.(c3)::8, enc.(bsl(c4, 4))::8,
908+ ?=, ?=, ?=, ?=>>
909+ <<c1::5, c2::3>> ->
910+ <<main::binary,
911+ enc.(c1)::8, enc.(bsl(c2, 2))::8, ?=, ?=,
912+ ?=, ?=, ?=, ?=>>
913+ <<>> ->
914+ main
915+ end" )
916+
917+
853918; ; We don't want automatic whitespace cleanup here because of the significant
854919; ; whitespace after `Record' above. By setting `whitespace-action' to nil,
855920; ; `whitespace-mode' won't automatically clean up trailing whitespace (in my
0 commit comments