aboutsummaryrefslogtreecommitdiffstats
path: root/lib/compiler/test
diff options
context:
space:
mode:
authorBjörn Gustavsson <[email protected]>2012-08-23 09:58:17 +0200
committerBjörn Gustavsson <[email protected]>2012-08-23 09:58:17 +0200
commite7720fe2b2a1f09af70e74b54442f72f84609a31 (patch)
treed4fc0f35f41d9c9e1674af29510e797a118220fc /lib/compiler/test
parente479ebeb58beaa8261fa90e54681dc30e5ee3085 (diff)
parente4e5d08621137473674cf3cdce0b36a43a8d6d15 (diff)
downloadotp-e7720fe2b2a1f09af70e74b54442f72f84609a31.tar.gz
otp-e7720fe2b2a1f09af70e74b54442f72f84609a31.tar.bz2
otp-e7720fe2b2a1f09af70e74b54442f72f84609a31.zip
Merge branch 'bjorn/compiler/illegal-size/OTP-10197' into maint
* bjorn/compiler/illegal-size/OTP-10197: compiler: Warn if the size of a binary segment is invalid
Diffstat (limited to 'lib/compiler/test')
-rw-r--r--lib/compiler/test/bs_construct_SUITE.erl4
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/compiler/test/bs_construct_SUITE.erl b/lib/compiler/test/bs_construct_SUITE.erl
index 31c7890f26..e8b30f44ce 100644
--- a/lib/compiler/test/bs_construct_SUITE.erl
+++ b/lib/compiler/test/bs_construct_SUITE.erl
@@ -468,6 +468,10 @@ opt(Config) when is_list(Config) ->
?line {'EXIT',_} = (catch <<<<23,56,0,2>>:64/float>>),
?line {'EXIT',_} = (catch <<<<23,56,0,2:7>>/binary>>),
+ %% Test constant propagation - there should be a warning.
+ BadSz = 2.5,
+ {'EXIT',_} = (catch <<<<N,56,0,2>>:BadSz/binary>>),
+
case id(false) of
true -> ?line opt_dont_call_me();
false -> ok