Skip to content

Commit a9a8ece

Browse files
authored
Move builtin-array-fromasync.h to toplevel (#1034)
Putting it in gen/ is inconvenient for downstream users that vendor or repackage the source files.
1 parent 865ba1f commit a9a8ece

File tree

4 files changed

+4
-4
lines changed

4 files changed

+4
-4
lines changed

Makefile

+1-1
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ codegen: $(QJSC)
8080
$(QJSC) -e -o gen/hello.c examples/hello.js
8181
$(QJSC) -e -o gen/hello_module.c -m examples/hello_module.js
8282
$(QJSC) -e -o gen/test_fib.c -M examples/fib.so,fib -m examples/test_fib.js
83-
$(QJSC) -C -ss -o gen/builtin-array-fromasync.h builtin-array-fromasync.js
83+
$(QJSC) -C -ss -o builtin-array-fromasync.h builtin-array-fromasync.js
8484

8585
debug:
8686
BUILD_TYPE=Debug $(MAKE)

amalgam.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ const quickjs_libc_h = loadFile("quickjs-libc.h")
1818
const quickjs_opcode_h = loadFile("quickjs-opcode.h")
1919
const xsum_c = loadFile("xsum.c")
2020
const xsum_h = loadFile("xsum.h")
21-
const gen_builtin_array_fromasync_h = loadFile("gen/builtin-array-fromasync.h")
21+
const gen_builtin_array_fromasync_h = loadFile("builtin-array-fromasync.h")
2222

2323
let source = "#if defined(QJS_BUILD_LIBC) && defined(__linux__) && !defined(_GNU_SOURCE)\n"
2424
+ "#define _GNU_SOURCE\n"
@@ -43,7 +43,7 @@ let source = "#if defined(QJS_BUILD_LIBC) && defined(__linux__) && !defined(_GNU
4343
source = source.replace(/#include "quickjs-atom.h"/g, quickjs_atom_h)
4444
source = source.replace(/#include "quickjs-opcode.h"/g, quickjs_opcode_h)
4545
source = source.replace(/#include "libregexp-opcode.h"/g, libregexp_opcode_h)
46-
source = source.replace(/#include "gen\/builtin-array-fromasync.h"/g,
46+
source = source.replace(/#include "builtin-array-fromasync.h"/g,
4747
gen_builtin_array_fromasync_h)
4848
source = source.replace(/#include "[^"]+"/g, "")
4949
writeFile(execArgv[2] ?? "quickjs-amalgam.c", source)
File renamed without changes.

quickjs.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -7447,7 +7447,7 @@ int JS_IsInstanceOf(JSContext *ctx, JSValueConst val, JSValueConst obj)
74477447
return JS_OrdinaryIsInstanceOf(ctx, val, obj);
74487448
}
74497449

7450-
#include "gen/builtin-array-fromasync.h"
7450+
#include "builtin-array-fromasync.h"
74517451

74527452
static JSValue js_bytecode_autoinit(JSContext *ctx, JSObject *p, JSAtom atom,
74537453
void *opaque)

0 commit comments

Comments
 (0)