History

Bug 701355: Fix separate compilation issues that have crept in.

We normally build as one compilation unit with "one.c" but we should still be able to build each source file as a separate compilation unit if desired.

Tor Andersson committed 6 years ago

Commit 8ee595b1 parent d248b0c2 files · +9 −3Browse files

Unified · Split

2 files
  1. jsrepr.c +8 −3
  2. jsstate.c +1 −0
jsrepr.c+8−3
@@ -2,6 +2,8 @@ · 1 unmodified line
22 #include "jslex.h"
33 #include "jsvalue.h"
44 #include "jsbuiltin.h"
5+#include "jscompile.h"
6+#include "utf.h"
57
68 static void reprvalue(js_State *J, js_Buffer **sb);
79
@@ -193,9 +195,12 @@ static void reprvalue(js_State *J, js_Buffer **sb) · 185 unmodified lines
193195 if (obj->u.r.flags & JS_REGEXP_M) js_putc(J, sb, 'm');
194196 break;
195197 case JS_CDATE:
196− js_puts(J, sb, "(new Date(");
197− fmtnum(J, sb, obj->u.number);
198− js_puts(J, sb, "))");
198+ {
199+ char buf[40];
200+ js_puts(J, sb, "(new Date(");
201+ js_puts(J, sb, jsV_numbertostring(J, buf, obj->u.number));
202+ js_puts(J, sb, "))");
203+ }
199204 break;
200205 case JS_CERROR:
201206 js_puts(J, sb, "(new ");
jsstate.c+1−0
@@ -6,6 +6,7 @@ · 5 unmodified lines
66 #include "jsbuiltin.h"
77
88 #include <assert.h>
9+#include <errno.h>
910
1011 static void *js_defaultalloc(void *actx, void *ptr, int size)
1112 {

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t