aboutsummaryrefslogtreecommitdiffstats
path: root/src/editfns.c
diff options
context:
space:
mode:
authorJim Blandy1992-04-24 08:11:54 +0000
committerJim Blandy1992-04-24 08:11:54 +0000
commit4746118aca2d5cbdd054b4af4814d56550dfbc79 (patch)
tree370e07c6950794f936bc8d434cb0560d883e4a0b /src/editfns.c
parentd4327fecc103493bc8275c3580b05c06c9fcc019 (diff)
downloademacs-4746118aca2d5cbdd054b4af4814d56550dfbc79.tar.gz
emacs-4746118aca2d5cbdd054b4af4814d56550dfbc79.zip
*** empty log message ***
Diffstat (limited to 'src/editfns.c')
-rw-r--r--src/editfns.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/editfns.c b/src/editfns.c
index d0db0837591..0ef059aa055 100644
--- a/src/editfns.c
+++ b/src/editfns.c
@@ -1094,20 +1094,24 @@ Use %% to put a single % into the output.")
1094 /* Would get MPV otherwise, since Lisp_Int's `point' to low memory. */ 1094 /* Would get MPV otherwise, since Lisp_Int's `point' to low memory. */
1095 else if (XTYPE (args[n]) == Lisp_Int && *format != 's') 1095 else if (XTYPE (args[n]) == Lisp_Int && *format != 's')
1096 { 1096 {
1097#ifdef LISP_FLOAT_TYPE
1097 /* The following loop issumes the Lisp type indicates 1098 /* The following loop issumes the Lisp type indicates
1098 the proper way to pass the argument. 1099 the proper way to pass the argument.
1099 So make sure we have a flonum if the argument should 1100 So make sure we have a flonum if the argument should
1100 be a double. */ 1101 be a double. */
1101 if (*format == 'e' || *format == 'f' || *format == 'g') 1102 if (*format == 'e' || *format == 'f' || *format == 'g')
1102 args[n] = Ffloat (args[n]); 1103 args[n] = Ffloat (args[n]);
1104#endif
1103 total += 10; 1105 total += 10;
1104 } 1106 }
1107#ifdef LISP_FLOAT_TYPE
1105 else if (XTYPE (args[n]) == Lisp_Float && *format != 's') 1108 else if (XTYPE (args[n]) == Lisp_Float && *format != 's')
1106 { 1109 {
1107 if (! (*format == 'e' || *format == 'f' || *format == 'g')) 1110 if (! (*format == 'e' || *format == 'f' || *format == 'g'))
1108 args[n] = Ftruncate (args[n]); 1111 args[n] = Ftruncate (args[n]);
1109 total += 20; 1112 total += 20;
1110 } 1113 }
1114#endif
1111 else 1115 else
1112 { 1116 {
1113 /* Anything but a string, convert to a string using princ. */ 1117 /* Anything but a string, convert to a string using princ. */
@@ -1131,6 +1135,7 @@ Use %% to put a single % into the output.")
1131 /* We checked above that the corresponding format effector 1135 /* We checked above that the corresponding format effector
1132 isn't %s, which would cause MPV. */ 1136 isn't %s, which would cause MPV. */
1133 strings[n] = (unsigned char *) XINT (args[n]); 1137 strings[n] = (unsigned char *) XINT (args[n]);
1138#ifdef LISP_FLOAT_TYPE
1134 else if (XTYPE (args[n]) == Lisp_Float) 1139 else if (XTYPE (args[n]) == Lisp_Float)
1135 { 1140 {
1136 union { double d; int half[2]; } u; 1141 union { double d; int half[2]; } u;
@@ -1139,6 +1144,7 @@ Use %% to put a single % into the output.")
1139 strings[n++] = (unsigned char *) u.half[0]; 1144 strings[n++] = (unsigned char *) u.half[0];
1140 strings[n] = (unsigned char *) u.half[1]; 1145 strings[n] = (unsigned char *) u.half[1];
1141 } 1146 }
1147#endif
1142 else 1148 else
1143 strings[n] = XSTRING (args[n])->data; 1149 strings[n] = XSTRING (args[n])->data;
1144 } 1150 }