Upload Kmake

This commit is contained in:
Gorochu
2026-05-26 23:36:42 -07:00
parent ba051b2f74
commit 555ec72358
41615 changed files with 13344630 additions and 1 deletions

53
test/fixtures/eval/eval_messages.js vendored Normal file
View File

@ -0,0 +1,53 @@
// Copyright Joyent, Inc. and other Node contributors.
//
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the
// "Software"), to deal in the Software without restriction, including
// without limitation the rights to use, copy, modify, merge, publish,
// distribute, sublicense, and/or sell copies of the Software, and to permit
// persons to whom the Software is furnished to do so, subject to the
// following conditions:
//
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
// USE OR OTHER DEALINGS IN THE SOFTWARE.
'use strict';
require('../../common');
const spawn = require('child_process').spawn;
function run(cmd, strict, cb) {
const args = [];
if (strict) args.push('--use_strict');
args.push('-pe', cmd);
const child = spawn(process.execPath, args);
child.stdout.pipe(process.stdout);
child.stderr.pipe(process.stdout);
child.on('close', cb);
}
const queue =
[ 'with(this){__filename}',
'42',
'throw new Error("hello")',
'var x = 100; y = x;',
'var ______________________________________________; throw 10' ];
function go() {
const c = queue.shift();
if (!c) return console.log('done');
run(c, false, function() {
run(c, true, go);
});
}
go();

View File

@ -0,0 +1,50 @@
[eval]
[eval]:1
with(this){__filename}
^^^^
The 'with' statement is not supported. All symbols in a 'with' block will have type 'any'.
SyntaxError: Strict mode code may not include a with statement
Node.js *
42
42
[eval]:1
throw new Error("hello")
^
Error: hello
Node.js *
[eval]:1
throw new Error("hello")
^
Error: hello
Node.js *
100
[eval]:1
var x = 100; y = x;
^
ReferenceError: y is not defined
Node.js *
[eval]:1
var ______________________________________________; throw 10
^
10
(Use `* --trace-uncaught ...` to show where the exception was thrown)
Node.js *
[eval]:1
var ______________________________________________; throw 10
^
10
(Use `* --trace-uncaught ...` to show where the exception was thrown)
Node.js *
done

25
test/fixtures/eval/eval_typescript.js vendored Normal file
View File

@ -0,0 +1,25 @@
'use strict';
require('../../common');
const spawnSync = require('child_process').spawnSync;
const queue = [
'enum Foo{};',
'throw new SyntaxError("hello")',
'const foo;',
'let x: number = 100;x;',
'const foo: string = 10;',
'function foo(){};foo<Number>(1);',
'interface Foo{};const foo;',
'function foo(){ await Promise.resolve(1)};',
];
for (const cmd of queue) {
const args = ['--disable-warning=ExperimentalWarning', '-p', cmd];
const result = spawnSync(process.execPath, args, {
stdio: 'pipe',
});
process.stdout.write(result.stdout);
process.stdout.write(result.stderr);
}

View File

@ -0,0 +1,42 @@
[eval]:1
enum Foo{};
^^^^
TypeScript enum is not supported in strip-only mode
SyntaxError: Unexpected reserved word
Node.js *
[eval]:1
throw new SyntaxError("hello")
^
SyntaxError: hello
Node.js *
[eval]:1
const foo;
^^^
'const' declarations must be initialized
SyntaxError: Missing initializer in const declaration
Node.js *
100
undefined
false
[eval]:1
interface Foo{};const foo;
^^^
'const' declarations must be initialized
SyntaxError: Unexpected identifier 'Foo'
Node.js *
[eval]:1
function foo(){ await Promise.resolve(1)};
^^^^^
await isn't allowed in non-async function
SyntaxError: await is only valid in async functions and the top level bodies of modules
Node.js *

54
test/fixtures/eval/stdin_messages.js vendored Normal file
View File

@ -0,0 +1,54 @@
// Copyright Joyent, Inc. and other Node contributors.
//
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the
// "Software"), to deal in the Software without restriction, including
// without limitation the rights to use, copy, modify, merge, publish,
// distribute, sublicense, and/or sell copies of the Software, and to permit
// persons to whom the Software is furnished to do so, subject to the
// following conditions:
//
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
// USE OR OTHER DEALINGS IN THE SOFTWARE.
'use strict';
require('../../common');
const spawn = require('child_process').spawn;
function run(cmd, strict, cb) {
const args = [];
if (strict) args.push('--use_strict');
args.push('-p');
const child = spawn(process.execPath, args);
child.stdout.pipe(process.stdout);
child.stderr.pipe(process.stdout);
child.stdin.end(cmd);
child.on('close', cb);
}
const queue =
[ 'with(this){__filename}',
'42',
'throw new Error("hello")',
'let x = 100; y = x;',
'let ______________________________________________; throw 10' ];
function go() {
const c = queue.shift();
if (!c) return console.log('done');
run(c, false, function() {
run(c, true, go);
});
}
go();

View File

@ -0,0 +1,50 @@
[stdin]
[stdin]:1
with(this){__filename}
^^^^
The 'with' statement is not supported. All symbols in a 'with' block will have type 'any'.
SyntaxError: Strict mode code may not include a with statement
Node.js *
42
42
[stdin]:1
throw new Error("hello")
^
Error: hello
Node.js *
[stdin]:1
throw new Error("hello")
^
Error: hello
Node.js *
100
[stdin]:1
let x = 100; y = x;
^
ReferenceError: y is not defined
Node.js *
[stdin]:1
let ______________________________________________; throw 10
^
10
(Use `* --trace-uncaught ...` to show where the exception was thrown)
Node.js *
[stdin]:1
let ______________________________________________; throw 10
^
10
(Use `* --trace-uncaught ...` to show where the exception was thrown)
Node.js *
done

38
test/fixtures/eval/stdin_typescript.js vendored Normal file
View File

@ -0,0 +1,38 @@
'use strict';
require('../../common');
const spawn = require('child_process').spawn;
function run(cmd, strict, cb) {
const args = ['--disable-warning=ExperimentalWarning'];
if (strict) args.push('--use_strict');
args.push('-p');
const child = spawn(process.execPath, args);
child.stdout.pipe(process.stdout);
child.stderr.pipe(process.stdout);
child.stdin.end(cmd);
child.on('close', cb);
}
const queue =
[
'enum Foo{};',
'throw new SyntaxError("hello")',
'const foo;',
'let x: number = 100;x;',
'const foo: string = 10;',
'function foo(){};foo<Number>(1);',
'interface Foo{};const foo;',
'function foo(){ await Promise.resolve(1)};',
];
function go() {
const c = queue.shift();
if (!c) return console.log('done');
run(c, false, function() {
run(c, true, go);
});
}
go();

View File

@ -0,0 +1,85 @@
[stdin]:1
enum Foo{};
^^^^
TypeScript enum is not supported in strip-only mode
SyntaxError: Unexpected reserved word
Node.js *
[stdin]:1
enum Foo{};
^^^^
TypeScript enum is not supported in strip-only mode
SyntaxError: Unexpected reserved word
Node.js *
[stdin]:1
throw new SyntaxError("hello")
^
SyntaxError: hello
Node.js *
[stdin]:1
throw new SyntaxError("hello")
^
SyntaxError: hello
Node.js *
[stdin]:1
const foo;
^^^
'const' declarations must be initialized
SyntaxError: Missing initializer in const declaration
Node.js *
[stdin]:1
const foo;
^^^
'const' declarations must be initialized
SyntaxError: Missing initializer in const declaration
Node.js *
100
100
undefined
undefined
false
false
[stdin]:1
interface Foo{};const foo;
^^^
'const' declarations must be initialized
SyntaxError: Unexpected identifier 'Foo'
Node.js *
[stdin]:1
interface Foo{};const foo;
^^^^^^^^^
'const' declarations must be initialized
SyntaxError: Unexpected strict mode reserved word
Node.js *
[stdin]:1
function foo(){ await Promise.resolve(1)};
^^^^^
await isn't allowed in non-async function
SyntaxError: await is only valid in async functions and the top level bodies of modules
Node.js *
[stdin]:1
function foo(){ await Promise.resolve(1)};
^^^^^
await isn't allowed in non-async function
SyntaxError: await is only valid in async functions and the top level bodies of modules
Node.js *
done