aboutsummaryrefslogtreecommitdiffstats
path: root/erts/emulator/beam/beam_load.c
diff options
context:
space:
mode:
authorBjörn Gustavsson <[email protected]>2017-08-28 13:06:20 +0200
committerBjörn Gustavsson <[email protected]>2017-08-28 13:25:57 +0200
commitc49cdbe34e979dabcda56a05e4a104a9693fc56c (patch)
tree77799d988eba0592b979c8ec1b512ab7e1e467bc /erts/emulator/beam/beam_load.c
parent7d8beec59350c1b3e92cee50c222f8e2ccdd30d5 (diff)
downloadotp-c49cdbe34e979dabcda56a05e4a104a9693fc56c.tar.gz
otp-c49cdbe34e979dabcda56a05e4a104a9693fc56c.tar.bz2
otp-c49cdbe34e979dabcda56a05e4a104a9693fc56c.zip
Remove backward compatibility support for float literals
Starting from R16B, floating point constants are stored in the literal pool. The backward compatibility support for the old representation of floats has been kept long enough. Also, we might want to ensure that all literals are unique in the future, and we certainly don't want to update this code to ensure uniqueness.
Diffstat (limited to 'erts/emulator/beam/beam_load.c')
-rw-r--r--erts/emulator/beam/beam_load.c26
1 files changed, 3 insertions, 23 deletions
diff --git a/erts/emulator/beam/beam_load.c b/erts/emulator/beam/beam_load.c
index 9ff32e30f3..cc3219989e 100644
--- a/erts/emulator/beam/beam_load.c
+++ b/erts/emulator/beam/beam_load.c
@@ -2034,30 +2034,10 @@ load_code(LoaderState* stp)
case 0:
/* Floating point number.
* Not generated by the compiler in R16B and later.
+ * (The literal pool is used instead.)
*/
- {
- Eterm* hp;
-#if !defined(ARCH_64)
- Uint high, low;
-# endif
- last_op->a[arg].val = new_literal(stp, &hp,
- FLOAT_SIZE_OBJECT);
- hp[0] = HEADER_FLONUM;
- last_op->a[arg].type = TAG_q;
-#if defined(ARCH_64)
- GetInt(stp, 8, hp[1]);
-# else
- GetInt(stp, 4, high);
- GetInt(stp, 4, low);
- if (must_swap_floats) {
- Uint t = high;
- high = low;
- low = t;
- }
- hp[1] = high;
- hp[2] = low;
-# endif
- }
+ LoadError0(stp, "please re-compile this module with an "
+ ERLANG_OTP_RELEASE " compiler");
break;
case 1: /* List. */
if (arg+1 != arity) {