@vituum/vite-plugin-latte 0.1.10 → 0.1.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/handler.js +7 -4
- package/index.js +18 -5
- package/index.php +12 -6
- package/latte/AssetFilter.php +1 -1
- package/package.json +3 -2
- package/vendor/autoload.php +1 -6
- package/vendor/bin/latte-lint +1 -14
- package/vendor/composer/InstalledVersions.php +7 -9
- package/vendor/composer/autoload_classmap.php +7 -10
- package/vendor/composer/autoload_namespaces.php +1 -1
- package/vendor/composer/autoload_psr4.php +1 -1
- package/vendor/composer/autoload_real.php +26 -7
- package/vendor/composer/autoload_static.php +8 -11
- package/vendor/composer/installed.json +7 -7
- package/vendor/composer/installed.php +6 -6
- package/vendor/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/FunctionCallNode.php +2 -11
- package/vendor/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/{UndefinedsafePropertyFetchNode.php → FunctionCallableNode.php} +6 -9
- package/vendor/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/MethodCallNode.php +4 -13
- package/vendor/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/{NullsafePropertyFetchNode.php → MethodCallableNode.php} +5 -4
- package/vendor/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/PropertyFetchNode.php +2 -1
- package/vendor/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/StaticCallNode.php +2 -12
- package/vendor/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/{NullsafeMethodCallNode.php → StaticCallableNode.php} +12 -14
- package/vendor/latte/latte/src/Latte/Compiler/Nodes/Php/Scalar/EncapsedStringNode.php +8 -6
- package/vendor/latte/latte/src/Latte/Compiler/PrintContext.php +6 -3
- package/vendor/latte/latte/src/Latte/Compiler/TagLexer.php +23 -6
- package/vendor/latte/latte/src/Latte/Compiler/TagParser.php +87 -0
- package/vendor/latte/latte/src/Latte/Compiler/TagParserData.php +306 -285
- package/vendor/latte/latte/src/Latte/Compiler/TemplateLexer.php +31 -43
- package/vendor/latte/latte/src/Latte/Compiler/Token.php +17 -13
- package/vendor/latte/latte/src/Latte/Engine.php +2 -2
- package/vendor/latte/latte/src/Latte/Essential/CoreExtension.php +4 -2
- package/vendor/latte/latte/src/Latte/Essential/Passes.php +1 -1
- package/vendor/latte/latte/src/Latte/Essential/TranslatorExtension.php +2 -2
- package/vendor/latte/latte/src/Latte/Sandbox/Nodes/FunctionCallNode.php +0 -5
- package/vendor/latte/latte/src/Latte/Sandbox/Nodes/FunctionCallableNode.php +29 -0
- package/vendor/latte/latte/src/Latte/Sandbox/Nodes/MethodCallNode.php +3 -8
- package/vendor/latte/latte/src/Latte/Sandbox/Nodes/{NullsafePropertyFetchNode.php → MethodCallableNode.php} +4 -6
- package/vendor/latte/latte/src/Latte/Sandbox/Nodes/PropertyFetchNode.php +2 -2
- package/vendor/latte/latte/src/Latte/Sandbox/Nodes/StaticCallNode.php +0 -6
- package/vendor/latte/latte/src/Latte/Sandbox/Nodes/StaticCallableNode.php +30 -0
- package/vendor/latte/latte/src/Latte/Sandbox/SandboxExtension.php +3 -5
- package/vendor/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/UndefinedsafeMethodCallNode.php +0 -49
- package/vendor/latte/latte/src/Latte/Compiler/Nodes/Php/VariadicPlaceholderNode.php +0 -29
- package/vendor/latte/latte/src/Latte/Sandbox/Nodes/NullsafeMethodCallNode.php +0 -31
- package/vendor/latte/latte/src/Latte/Sandbox/Nodes/UndefinedsafeMethodCallNode.php +0 -31
- package/vendor/latte/latte/src/Latte/Sandbox/Nodes/UndefinedsafePropertyFetchNode.php +0 -32
package/handler.js
CHANGED
|
@@ -1,9 +1,12 @@
|
|
|
1
1
|
import { resolve } from 'path'
|
|
2
2
|
|
|
3
3
|
const vite = (await import(resolve(process.cwd(), 'vite.config.js'))).default
|
|
4
|
-
|
|
5
|
-
const name =
|
|
4
|
+
let params = JSON.parse(process.argv[4])
|
|
5
|
+
const name = process.argv[2]
|
|
6
|
+
const type = process.argv[3]
|
|
6
7
|
|
|
7
|
-
params.
|
|
8
|
+
params = params.map(value => Buffer.from(value, 'base64').toString('utf-8'))
|
|
8
9
|
|
|
9
|
-
vite.plugins.filter(({ name }) => name === '@vituum/vite-plugin-latte')[0]._params
|
|
10
|
+
const output = await vite.plugins.filter(({ name }) => name === '@vituum/vite-plugin-latte')[0]._params[type][name](...params)
|
|
11
|
+
|
|
12
|
+
console.log(Buffer.from(output.toString(), 'utf-8').toString('base64'))
|
package/index.js
CHANGED
|
@@ -1,10 +1,11 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { resolve, dirname } from 'path'
|
|
2
2
|
import { fileURLToPath } from 'url'
|
|
3
3
|
import fs from 'fs'
|
|
4
4
|
import process from 'node:process'
|
|
5
5
|
import * as childProcess from 'child_process'
|
|
6
6
|
import FastGlob from 'fast-glob'
|
|
7
7
|
import lodash from 'lodash'
|
|
8
|
+
import chalk from 'chalk'
|
|
8
9
|
|
|
9
10
|
const defaultParams = {
|
|
10
11
|
reload: true,
|
|
@@ -93,6 +94,11 @@ const latte = (params = {}) => {
|
|
|
93
94
|
transformIndexHtml: {
|
|
94
95
|
enforce: 'pre',
|
|
95
96
|
async transform(content, { path, filename, server }) {
|
|
97
|
+
path = path.replace('?raw', '')
|
|
98
|
+
filename = filename.replace('?raw', '')
|
|
99
|
+
|
|
100
|
+
const start = new Date()
|
|
101
|
+
|
|
96
102
|
if (
|
|
97
103
|
!params.filetypes.html.test(path) &&
|
|
98
104
|
!params.filetypes.json.test(path) &&
|
|
@@ -108,20 +114,27 @@ const latte = (params = {}) => {
|
|
|
108
114
|
}
|
|
109
115
|
|
|
110
116
|
const renderLatte = renderTemplate(path, params, content)
|
|
117
|
+
const warningLog = renderLatte.output.includes('Warning: Undefined')
|
|
118
|
+
|
|
119
|
+
console.info(`${chalk.cyan('@vituum/vite-plugin-latte')} ${chalk.green(`finished in ${chalk.grey(new Date() - start + 'ms')}`)}`)
|
|
111
120
|
|
|
112
|
-
if (renderLatte.error) {
|
|
121
|
+
if (renderLatte.error || warningLog) {
|
|
113
122
|
if (!server) {
|
|
114
123
|
console.error(renderLatte.output)
|
|
115
124
|
return
|
|
116
125
|
}
|
|
117
126
|
|
|
127
|
+
const message = warningLog ? 'Warning: Undefined' + renderLatte.output.split('Warning: Undefined').pop() : renderLatte.output
|
|
128
|
+
|
|
118
129
|
server.ws.send({
|
|
119
130
|
type: 'error',
|
|
120
131
|
err: {
|
|
121
|
-
message
|
|
132
|
+
message,
|
|
122
133
|
plugin: '@vituum/vite-plugin-latte'
|
|
123
134
|
}
|
|
124
135
|
})
|
|
136
|
+
|
|
137
|
+
return
|
|
125
138
|
}
|
|
126
139
|
|
|
127
140
|
return renderLatte.output
|
|
@@ -129,8 +142,8 @@ const latte = (params = {}) => {
|
|
|
129
142
|
},
|
|
130
143
|
handleHotUpdate({ file, server }) {
|
|
131
144
|
if (
|
|
132
|
-
typeof params.reload === 'function' && params.reload(file) ||
|
|
133
|
-
params.reload && (params.filetypes.html.test(file) || params.filetypes.json.test(file))
|
|
145
|
+
(typeof params.reload === 'function' && params.reload(file)) ||
|
|
146
|
+
(typeof params.reload === 'boolean' && params.reload && (params.filetypes.html.test(file) || params.filetypes.json.test(file)))
|
|
134
147
|
) {
|
|
135
148
|
server.ws.send({ type: 'full-reload' })
|
|
136
149
|
}
|
package/index.php
CHANGED
|
@@ -32,12 +32,12 @@ define("PACKAGE_DIR", str_replace($config->cwd, ROOT_DIR, $config->packageRoot))
|
|
|
32
32
|
/**
|
|
33
33
|
* @throws JsonException
|
|
34
34
|
*/
|
|
35
|
-
function NodeHandler($name, ...$params) : string {
|
|
36
|
-
|
|
35
|
+
function NodeHandler($name, $type, ...$params) : string {
|
|
36
|
+
$params = array_map(static function($value) { return base64_encode((string)$value); }, $params);
|
|
37
37
|
|
|
38
|
-
|
|
38
|
+
exec('node '. PACKAGE_DIR .'/handler.js ' . $name . ' ' . $type .' ' . json_encode(json_encode($params, JSON_HEX_QUOT | JSON_HEX_TAG), JSON_THROW_ON_ERROR), $output);
|
|
39
39
|
|
|
40
|
-
|
|
40
|
+
return base64_decode($output[0] ?? '') ?? $params[1];
|
|
41
41
|
}
|
|
42
42
|
|
|
43
43
|
if (!file_exists(__DIR__ . '/temp') && !mkdir($concurrentDirectory = __DIR__ . '/temp') && !is_dir($concurrentDirectory)) {
|
|
@@ -127,7 +127,7 @@ foreach ($config->filters as $filter => $path) {
|
|
|
127
127
|
$latte->addFilter($filter, 'App\Latte\\' . ucfirst($filter) . 'Filter::execute');
|
|
128
128
|
} elseif (!$isDocker) {
|
|
129
129
|
$latte->addFilter($filter, function (...$params) use ($filter) : string {
|
|
130
|
-
return NodeHandler($filter, ...$params);
|
|
130
|
+
return NodeHandler($filter, 'filters', ...$params);
|
|
131
131
|
});
|
|
132
132
|
}
|
|
133
133
|
}
|
|
@@ -138,11 +138,17 @@ foreach ($config->functions as $function => $path) {
|
|
|
138
138
|
$latte->addFunction($function, 'App\Latte\\' . ucfirst($function) . 'Function::execute');
|
|
139
139
|
} elseif (!$isDocker) {
|
|
140
140
|
$latte->addFunction($function, function (...$params) use ($function) : string {
|
|
141
|
-
return NodeHandler($function, ...$params);
|
|
141
|
+
return NodeHandler($function, 'functions', ...$params);
|
|
142
142
|
});
|
|
143
143
|
}
|
|
144
144
|
}
|
|
145
145
|
|
|
146
|
+
$translator = static function (string $original): string {
|
|
147
|
+
return $original;
|
|
148
|
+
};
|
|
149
|
+
|
|
150
|
+
$latte->addExtension(new Latte\Essential\TranslatorExtension($translator));
|
|
151
|
+
|
|
146
152
|
$tag = 'json';
|
|
147
153
|
require PACKAGE_DIR . '/latte/' . ucfirst($tag) . 'Tag.php';
|
|
148
154
|
eval('$latte->addExtension(new App\Latte\\' . ucfirst($tag) . 'Extension);');
|
package/latte/AssetFilter.php
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vituum/vite-plugin-latte",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.13",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"scripts": {
|
|
@@ -10,7 +10,8 @@
|
|
|
10
10
|
},
|
|
11
11
|
"dependencies": {
|
|
12
12
|
"fast-glob": "^3.2.11",
|
|
13
|
-
"lodash": "^4.17.21"
|
|
13
|
+
"lodash": "^4.17.21",
|
|
14
|
+
"chalk": "^5.0.1"
|
|
14
15
|
},
|
|
15
16
|
"devDependencies": {
|
|
16
17
|
"vite": "^3.0.9",
|
package/vendor/autoload.php
CHANGED
|
@@ -2,11 +2,6 @@
|
|
|
2
2
|
|
|
3
3
|
// autoload.php @generated by Composer
|
|
4
4
|
|
|
5
|
-
if (PHP_VERSION_ID < 50600) {
|
|
6
|
-
echo 'Composer 2.3.0 dropped support for autoloading on PHP <5.6 and you are running '.PHP_VERSION.', please upgrade PHP or use Composer 2.2 LTS via "composer self-update --2.2". Aborting.'.PHP_EOL;
|
|
7
|
-
exit(1);
|
|
8
|
-
}
|
|
9
|
-
|
|
10
5
|
require_once __DIR__ . '/composer/autoload_real.php';
|
|
11
6
|
|
|
12
|
-
return
|
|
7
|
+
return ComposerAutoloaderInit19cfb30b66a778b432af39bbd1e78bca::getLoader();
|
package/vendor/bin/latte-lint
CHANGED
|
@@ -66,16 +66,6 @@ if (PHP_VERSION_ID < 80000) {
|
|
|
66
66
|
return $operation ? flock($this->handle, $operation) : true;
|
|
67
67
|
}
|
|
68
68
|
|
|
69
|
-
public function stream_seek($offset, $whence)
|
|
70
|
-
{
|
|
71
|
-
if (0 === fseek($this->handle, $offset, $whence)) {
|
|
72
|
-
$this->position = ftell($this->handle);
|
|
73
|
-
return true;
|
|
74
|
-
}
|
|
75
|
-
|
|
76
|
-
return false;
|
|
77
|
-
}
|
|
78
|
-
|
|
79
69
|
public function stream_tell()
|
|
80
70
|
{
|
|
81
71
|
return $this->position;
|
|
@@ -108,10 +98,7 @@ if (PHP_VERSION_ID < 80000) {
|
|
|
108
98
|
}
|
|
109
99
|
}
|
|
110
100
|
|
|
111
|
-
if (
|
|
112
|
-
(function_exists('stream_get_wrappers') && in_array('phpvfscomposer', stream_get_wrappers(), true))
|
|
113
|
-
|| (function_exists('stream_wrapper_register') && stream_wrapper_register('phpvfscomposer', 'Composer\BinProxyWrapper'))
|
|
114
|
-
) {
|
|
101
|
+
if (function_exists('stream_wrapper_register') && stream_wrapper_register('phpvfscomposer', 'Composer\BinProxyWrapper')) {
|
|
115
102
|
include("phpvfscomposer://" . __DIR__ . '/..'.'/latte/latte/bin/latte-lint');
|
|
116
103
|
exit(0);
|
|
117
104
|
}
|
|
@@ -21,14 +21,12 @@ use Composer\Semver\VersionParser;
|
|
|
21
21
|
* See also https://getcomposer.org/doc/07-runtime.md#installed-versions
|
|
22
22
|
*
|
|
23
23
|
* To require its presence, you can require `composer-runtime-api ^2.0`
|
|
24
|
-
*
|
|
25
|
-
* @final
|
|
26
24
|
*/
|
|
27
25
|
class InstalledVersions
|
|
28
26
|
{
|
|
29
27
|
/**
|
|
30
28
|
* @var mixed[]|null
|
|
31
|
-
* @psalm-var array{root: array{name: string,
|
|
29
|
+
* @psalm-var array{root: array{name: string, version: string, reference: string, pretty_version: string, aliases: string[], dev: bool, install_path: string, type: string}, versions: array<string, array{dev_requirement: bool, pretty_version?: string, version?: string, aliases?: string[], reference?: string, replaced?: string[], provided?: string[], install_path?: string, type?: string}>}|array{}|null
|
|
32
30
|
*/
|
|
33
31
|
private static $installed;
|
|
34
32
|
|
|
@@ -39,7 +37,7 @@ class InstalledVersions
|
|
|
39
37
|
|
|
40
38
|
/**
|
|
41
39
|
* @var array[]
|
|
42
|
-
* @psalm-var array<string, array{root: array{name: string,
|
|
40
|
+
* @psalm-var array<string, array{root: array{name: string, version: string, reference: string, pretty_version: string, aliases: string[], dev: bool, install_path: string, type: string}, versions: array<string, array{dev_requirement: bool, pretty_version?: string, version?: string, aliases?: string[], reference?: string, replaced?: string[], provided?: string[], install_path?: string, type?: string}>}>
|
|
43
41
|
*/
|
|
44
42
|
private static $installedByVendor = array();
|
|
45
43
|
|
|
@@ -243,7 +241,7 @@ class InstalledVersions
|
|
|
243
241
|
|
|
244
242
|
/**
|
|
245
243
|
* @return array
|
|
246
|
-
* @psalm-return array{name: string,
|
|
244
|
+
* @psalm-return array{name: string, version: string, reference: string, pretty_version: string, aliases: string[], dev: bool, install_path: string, type: string}
|
|
247
245
|
*/
|
|
248
246
|
public static function getRootPackage()
|
|
249
247
|
{
|
|
@@ -257,7 +255,7 @@ class InstalledVersions
|
|
|
257
255
|
*
|
|
258
256
|
* @deprecated Use getAllRawData() instead which returns all datasets for all autoloaders present in the process. getRawData only returns the first dataset loaded, which may not be what you expect.
|
|
259
257
|
* @return array[]
|
|
260
|
-
* @psalm-return array{root: array{name: string,
|
|
258
|
+
* @psalm-return array{root: array{name: string, version: string, reference: string, pretty_version: string, aliases: string[], dev: bool, install_path: string, type: string}, versions: array<string, array{dev_requirement: bool, pretty_version?: string, version?: string, aliases?: string[], reference?: string, replaced?: string[], provided?: string[], install_path?: string, type?: string}>}
|
|
261
259
|
*/
|
|
262
260
|
public static function getRawData()
|
|
263
261
|
{
|
|
@@ -280,7 +278,7 @@ class InstalledVersions
|
|
|
280
278
|
* Returns the raw data of all installed.php which are currently loaded for custom implementations
|
|
281
279
|
*
|
|
282
280
|
* @return array[]
|
|
283
|
-
* @psalm-return list<array{root: array{name: string,
|
|
281
|
+
* @psalm-return list<array{root: array{name: string, version: string, reference: string, pretty_version: string, aliases: string[], dev: bool, install_path: string, type: string}, versions: array<string, array{dev_requirement: bool, pretty_version?: string, version?: string, aliases?: string[], reference?: string, replaced?: string[], provided?: string[], install_path?: string, type?: string}>}>
|
|
284
282
|
*/
|
|
285
283
|
public static function getAllRawData()
|
|
286
284
|
{
|
|
@@ -303,7 +301,7 @@ class InstalledVersions
|
|
|
303
301
|
* @param array[] $data A vendor/composer/installed.php data set
|
|
304
302
|
* @return void
|
|
305
303
|
*
|
|
306
|
-
* @psalm-param array{root: array{name: string,
|
|
304
|
+
* @psalm-param array{root: array{name: string, version: string, reference: string, pretty_version: string, aliases: string[], dev: bool, install_path: string, type: string}, versions: array<string, array{dev_requirement: bool, pretty_version?: string, version?: string, aliases?: string[], reference?: string, replaced?: string[], provided?: string[], install_path?: string, type?: string}>} $data
|
|
307
305
|
*/
|
|
308
306
|
public static function reload($data)
|
|
309
307
|
{
|
|
@@ -313,7 +311,7 @@ class InstalledVersions
|
|
|
313
311
|
|
|
314
312
|
/**
|
|
315
313
|
* @return array[]
|
|
316
|
-
* @psalm-return list<array{root: array{name: string,
|
|
314
|
+
* @psalm-return list<array{root: array{name: string, version: string, reference: string, pretty_version: string, aliases: string[], dev: bool, install_path: string, type: string}, versions: array<string, array{dev_requirement: bool, pretty_version?: string, version?: string, aliases?: string[], reference?: string, replaced?: string[], provided?: string[], install_path?: string, type?: string}>}>
|
|
317
315
|
*/
|
|
318
316
|
private static function getInstalled()
|
|
319
317
|
{
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
// autoload_classmap.php @generated by Composer
|
|
4
4
|
|
|
5
|
-
$vendorDir = dirname(
|
|
5
|
+
$vendorDir = dirname(dirname(__FILE__));
|
|
6
6
|
$baseDir = dirname($vendorDir);
|
|
7
7
|
|
|
8
8
|
return array(
|
|
@@ -46,24 +46,23 @@ return array(
|
|
|
46
46
|
'Latte\\Compiler\\Nodes\\Php\\Expression\\ErrorSuppressNode' => $vendorDir . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/ErrorSuppressNode.php',
|
|
47
47
|
'Latte\\Compiler\\Nodes\\Php\\Expression\\FilterCallNode' => $vendorDir . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/FilterCallNode.php',
|
|
48
48
|
'Latte\\Compiler\\Nodes\\Php\\Expression\\FunctionCallNode' => $vendorDir . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/FunctionCallNode.php',
|
|
49
|
+
'Latte\\Compiler\\Nodes\\Php\\Expression\\FunctionCallableNode' => $vendorDir . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/FunctionCallableNode.php',
|
|
49
50
|
'Latte\\Compiler\\Nodes\\Php\\Expression\\InRangeNode' => $vendorDir . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/InRangeNode.php',
|
|
50
51
|
'Latte\\Compiler\\Nodes\\Php\\Expression\\InstanceofNode' => $vendorDir . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/InstanceofNode.php',
|
|
51
52
|
'Latte\\Compiler\\Nodes\\Php\\Expression\\IssetNode' => $vendorDir . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/IssetNode.php',
|
|
52
53
|
'Latte\\Compiler\\Nodes\\Php\\Expression\\MatchNode' => $vendorDir . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/MatchNode.php',
|
|
53
54
|
'Latte\\Compiler\\Nodes\\Php\\Expression\\MethodCallNode' => $vendorDir . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/MethodCallNode.php',
|
|
55
|
+
'Latte\\Compiler\\Nodes\\Php\\Expression\\MethodCallableNode' => $vendorDir . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/MethodCallableNode.php',
|
|
54
56
|
'Latte\\Compiler\\Nodes\\Php\\Expression\\NewNode' => $vendorDir . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/NewNode.php',
|
|
55
57
|
'Latte\\Compiler\\Nodes\\Php\\Expression\\NotNode' => $vendorDir . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/NotNode.php',
|
|
56
|
-
'Latte\\Compiler\\Nodes\\Php\\Expression\\NullsafeMethodCallNode' => $vendorDir . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/NullsafeMethodCallNode.php',
|
|
57
|
-
'Latte\\Compiler\\Nodes\\Php\\Expression\\NullsafePropertyFetchNode' => $vendorDir . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/NullsafePropertyFetchNode.php',
|
|
58
58
|
'Latte\\Compiler\\Nodes\\Php\\Expression\\PostOpNode' => $vendorDir . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/PostOpNode.php',
|
|
59
59
|
'Latte\\Compiler\\Nodes\\Php\\Expression\\PreOpNode' => $vendorDir . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/PreOpNode.php',
|
|
60
60
|
'Latte\\Compiler\\Nodes\\Php\\Expression\\PropertyFetchNode' => $vendorDir . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/PropertyFetchNode.php',
|
|
61
61
|
'Latte\\Compiler\\Nodes\\Php\\Expression\\StaticCallNode' => $vendorDir . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/StaticCallNode.php',
|
|
62
|
+
'Latte\\Compiler\\Nodes\\Php\\Expression\\StaticCallableNode' => $vendorDir . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/StaticCallableNode.php',
|
|
62
63
|
'Latte\\Compiler\\Nodes\\Php\\Expression\\StaticPropertyFetchNode' => $vendorDir . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/StaticPropertyFetchNode.php',
|
|
63
64
|
'Latte\\Compiler\\Nodes\\Php\\Expression\\TernaryNode' => $vendorDir . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/TernaryNode.php',
|
|
64
65
|
'Latte\\Compiler\\Nodes\\Php\\Expression\\UnaryOpNode' => $vendorDir . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/UnaryOpNode.php',
|
|
65
|
-
'Latte\\Compiler\\Nodes\\Php\\Expression\\UndefinedsafeMethodCallNode' => $vendorDir . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/UndefinedsafeMethodCallNode.php',
|
|
66
|
-
'Latte\\Compiler\\Nodes\\Php\\Expression\\UndefinedsafePropertyFetchNode' => $vendorDir . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/UndefinedsafePropertyFetchNode.php',
|
|
67
66
|
'Latte\\Compiler\\Nodes\\Php\\Expression\\VariableNode' => $vendorDir . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/VariableNode.php',
|
|
68
67
|
'Latte\\Compiler\\Nodes\\Php\\FilterNode' => $vendorDir . '/latte/latte/src/Latte/Compiler/Nodes/Php/FilterNode.php',
|
|
69
68
|
'Latte\\Compiler\\Nodes\\Php\\IdentifierNode' => $vendorDir . '/latte/latte/src/Latte/Compiler/Nodes/Php/IdentifierNode.php',
|
|
@@ -84,7 +83,6 @@ return array(
|
|
|
84
83
|
'Latte\\Compiler\\Nodes\\Php\\SuperiorTypeNode' => $vendorDir . '/latte/latte/src/Latte/Compiler/Nodes/Php/SuperiorTypeNode.php',
|
|
85
84
|
'Latte\\Compiler\\Nodes\\Php\\UnionTypeNode' => $vendorDir . '/latte/latte/src/Latte/Compiler/Nodes/Php/UnionTypeNode.php',
|
|
86
85
|
'Latte\\Compiler\\Nodes\\Php\\VarLikeIdentifierNode' => $vendorDir . '/latte/latte/src/Latte/Compiler/Nodes/Php/VarLikeIdentifierNode.php',
|
|
87
|
-
'Latte\\Compiler\\Nodes\\Php\\VariadicPlaceholderNode' => $vendorDir . '/latte/latte/src/Latte/Compiler/Nodes/Php/VariadicPlaceholderNode.php',
|
|
88
86
|
'Latte\\Compiler\\Nodes\\StatementNode' => $vendorDir . '/latte/latte/src/Latte/Compiler/Nodes/StatementNode.php',
|
|
89
87
|
'Latte\\Compiler\\Nodes\\TemplateNode' => $vendorDir . '/latte/latte/src/Latte/Compiler/Nodes/TemplateNode.php',
|
|
90
88
|
'Latte\\Compiler\\Nodes\\TextNode' => $vendorDir . '/latte/latte/src/Latte/Compiler/Nodes/TextNode.php',
|
|
@@ -168,15 +166,14 @@ return array(
|
|
|
168
166
|
'Latte\\Runtime\\HtmlStringable' => $vendorDir . '/latte/latte/src/Latte/Runtime/HtmlStringable.php',
|
|
169
167
|
'Latte\\Runtime\\Template' => $vendorDir . '/latte/latte/src/Latte/Runtime/Template.php',
|
|
170
168
|
'Latte\\Sandbox\\Nodes\\FunctionCallNode' => $vendorDir . '/latte/latte/src/Latte/Sandbox/Nodes/FunctionCallNode.php',
|
|
169
|
+
'Latte\\Sandbox\\Nodes\\FunctionCallableNode' => $vendorDir . '/latte/latte/src/Latte/Sandbox/Nodes/FunctionCallableNode.php',
|
|
171
170
|
'Latte\\Sandbox\\Nodes\\MethodCallNode' => $vendorDir . '/latte/latte/src/Latte/Sandbox/Nodes/MethodCallNode.php',
|
|
172
|
-
'Latte\\Sandbox\\Nodes\\
|
|
173
|
-
'Latte\\Sandbox\\Nodes\\NullsafePropertyFetchNode' => $vendorDir . '/latte/latte/src/Latte/Sandbox/Nodes/NullsafePropertyFetchNode.php',
|
|
171
|
+
'Latte\\Sandbox\\Nodes\\MethodCallableNode' => $vendorDir . '/latte/latte/src/Latte/Sandbox/Nodes/MethodCallableNode.php',
|
|
174
172
|
'Latte\\Sandbox\\Nodes\\PropertyFetchNode' => $vendorDir . '/latte/latte/src/Latte/Sandbox/Nodes/PropertyFetchNode.php',
|
|
175
173
|
'Latte\\Sandbox\\Nodes\\SandboxNode' => $vendorDir . '/latte/latte/src/Latte/Sandbox/Nodes/SandboxNode.php',
|
|
176
174
|
'Latte\\Sandbox\\Nodes\\StaticCallNode' => $vendorDir . '/latte/latte/src/Latte/Sandbox/Nodes/StaticCallNode.php',
|
|
175
|
+
'Latte\\Sandbox\\Nodes\\StaticCallableNode' => $vendorDir . '/latte/latte/src/Latte/Sandbox/Nodes/StaticCallableNode.php',
|
|
177
176
|
'Latte\\Sandbox\\Nodes\\StaticPropertyFetchNode' => $vendorDir . '/latte/latte/src/Latte/Sandbox/Nodes/StaticPropertyFetchNode.php',
|
|
178
|
-
'Latte\\Sandbox\\Nodes\\UndefinedsafeMethodCallNode' => $vendorDir . '/latte/latte/src/Latte/Sandbox/Nodes/UndefinedsafeMethodCallNode.php',
|
|
179
|
-
'Latte\\Sandbox\\Nodes\\UndefinedsafePropertyFetchNode' => $vendorDir . '/latte/latte/src/Latte/Sandbox/Nodes/UndefinedsafePropertyFetchNode.php',
|
|
180
177
|
'Latte\\Sandbox\\RuntimeChecker' => $vendorDir . '/latte/latte/src/Latte/Sandbox/RuntimeChecker.php',
|
|
181
178
|
'Latte\\Sandbox\\SandboxExtension' => $vendorDir . '/latte/latte/src/Latte/Sandbox/SandboxExtension.php',
|
|
182
179
|
'Latte\\Sandbox\\SecurityPolicy' => $vendorDir . '/latte/latte/src/Latte/Sandbox/SecurityPolicy.php',
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
// autoload_real.php @generated by Composer
|
|
4
4
|
|
|
5
|
-
class
|
|
5
|
+
class ComposerAutoloaderInit19cfb30b66a778b432af39bbd1e78bca
|
|
6
6
|
{
|
|
7
7
|
private static $loader;
|
|
8
8
|
|
|
@@ -24,12 +24,31 @@ class ComposerAutoloaderInitda1ce49ef3085539a79eddbb995629f3
|
|
|
24
24
|
|
|
25
25
|
require __DIR__ . '/platform_check.php';
|
|
26
26
|
|
|
27
|
-
spl_autoload_register(array('
|
|
28
|
-
self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(
|
|
29
|
-
spl_autoload_unregister(array('
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
27
|
+
spl_autoload_register(array('ComposerAutoloaderInit19cfb30b66a778b432af39bbd1e78bca', 'loadClassLoader'), true, true);
|
|
28
|
+
self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(\dirname(__FILE__)));
|
|
29
|
+
spl_autoload_unregister(array('ComposerAutoloaderInit19cfb30b66a778b432af39bbd1e78bca', 'loadClassLoader'));
|
|
30
|
+
|
|
31
|
+
$useStaticLoader = PHP_VERSION_ID >= 50600 && !defined('HHVM_VERSION') && (!function_exists('zend_loader_file_encoded') || !zend_loader_file_encoded());
|
|
32
|
+
if ($useStaticLoader) {
|
|
33
|
+
require __DIR__ . '/autoload_static.php';
|
|
34
|
+
|
|
35
|
+
call_user_func(\Composer\Autoload\ComposerStaticInit19cfb30b66a778b432af39bbd1e78bca::getInitializer($loader));
|
|
36
|
+
} else {
|
|
37
|
+
$map = require __DIR__ . '/autoload_namespaces.php';
|
|
38
|
+
foreach ($map as $namespace => $path) {
|
|
39
|
+
$loader->set($namespace, $path);
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
$map = require __DIR__ . '/autoload_psr4.php';
|
|
43
|
+
foreach ($map as $namespace => $path) {
|
|
44
|
+
$loader->setPsr4($namespace, $path);
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
$classMap = require __DIR__ . '/autoload_classmap.php';
|
|
48
|
+
if ($classMap) {
|
|
49
|
+
$loader->addClassMap($classMap);
|
|
50
|
+
}
|
|
51
|
+
}
|
|
33
52
|
|
|
34
53
|
$loader->register(true);
|
|
35
54
|
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
namespace Composer\Autoload;
|
|
6
6
|
|
|
7
|
-
class
|
|
7
|
+
class ComposerStaticInit19cfb30b66a778b432af39bbd1e78bca
|
|
8
8
|
{
|
|
9
9
|
public static $classMap = array (
|
|
10
10
|
'Composer\\InstalledVersions' => __DIR__ . '/..' . '/composer/InstalledVersions.php',
|
|
@@ -47,24 +47,23 @@ class ComposerStaticInitda1ce49ef3085539a79eddbb995629f3
|
|
|
47
47
|
'Latte\\Compiler\\Nodes\\Php\\Expression\\ErrorSuppressNode' => __DIR__ . '/..' . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/ErrorSuppressNode.php',
|
|
48
48
|
'Latte\\Compiler\\Nodes\\Php\\Expression\\FilterCallNode' => __DIR__ . '/..' . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/FilterCallNode.php',
|
|
49
49
|
'Latte\\Compiler\\Nodes\\Php\\Expression\\FunctionCallNode' => __DIR__ . '/..' . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/FunctionCallNode.php',
|
|
50
|
+
'Latte\\Compiler\\Nodes\\Php\\Expression\\FunctionCallableNode' => __DIR__ . '/..' . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/FunctionCallableNode.php',
|
|
50
51
|
'Latte\\Compiler\\Nodes\\Php\\Expression\\InRangeNode' => __DIR__ . '/..' . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/InRangeNode.php',
|
|
51
52
|
'Latte\\Compiler\\Nodes\\Php\\Expression\\InstanceofNode' => __DIR__ . '/..' . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/InstanceofNode.php',
|
|
52
53
|
'Latte\\Compiler\\Nodes\\Php\\Expression\\IssetNode' => __DIR__ . '/..' . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/IssetNode.php',
|
|
53
54
|
'Latte\\Compiler\\Nodes\\Php\\Expression\\MatchNode' => __DIR__ . '/..' . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/MatchNode.php',
|
|
54
55
|
'Latte\\Compiler\\Nodes\\Php\\Expression\\MethodCallNode' => __DIR__ . '/..' . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/MethodCallNode.php',
|
|
56
|
+
'Latte\\Compiler\\Nodes\\Php\\Expression\\MethodCallableNode' => __DIR__ . '/..' . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/MethodCallableNode.php',
|
|
55
57
|
'Latte\\Compiler\\Nodes\\Php\\Expression\\NewNode' => __DIR__ . '/..' . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/NewNode.php',
|
|
56
58
|
'Latte\\Compiler\\Nodes\\Php\\Expression\\NotNode' => __DIR__ . '/..' . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/NotNode.php',
|
|
57
|
-
'Latte\\Compiler\\Nodes\\Php\\Expression\\NullsafeMethodCallNode' => __DIR__ . '/..' . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/NullsafeMethodCallNode.php',
|
|
58
|
-
'Latte\\Compiler\\Nodes\\Php\\Expression\\NullsafePropertyFetchNode' => __DIR__ . '/..' . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/NullsafePropertyFetchNode.php',
|
|
59
59
|
'Latte\\Compiler\\Nodes\\Php\\Expression\\PostOpNode' => __DIR__ . '/..' . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/PostOpNode.php',
|
|
60
60
|
'Latte\\Compiler\\Nodes\\Php\\Expression\\PreOpNode' => __DIR__ . '/..' . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/PreOpNode.php',
|
|
61
61
|
'Latte\\Compiler\\Nodes\\Php\\Expression\\PropertyFetchNode' => __DIR__ . '/..' . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/PropertyFetchNode.php',
|
|
62
62
|
'Latte\\Compiler\\Nodes\\Php\\Expression\\StaticCallNode' => __DIR__ . '/..' . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/StaticCallNode.php',
|
|
63
|
+
'Latte\\Compiler\\Nodes\\Php\\Expression\\StaticCallableNode' => __DIR__ . '/..' . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/StaticCallableNode.php',
|
|
63
64
|
'Latte\\Compiler\\Nodes\\Php\\Expression\\StaticPropertyFetchNode' => __DIR__ . '/..' . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/StaticPropertyFetchNode.php',
|
|
64
65
|
'Latte\\Compiler\\Nodes\\Php\\Expression\\TernaryNode' => __DIR__ . '/..' . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/TernaryNode.php',
|
|
65
66
|
'Latte\\Compiler\\Nodes\\Php\\Expression\\UnaryOpNode' => __DIR__ . '/..' . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/UnaryOpNode.php',
|
|
66
|
-
'Latte\\Compiler\\Nodes\\Php\\Expression\\UndefinedsafeMethodCallNode' => __DIR__ . '/..' . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/UndefinedsafeMethodCallNode.php',
|
|
67
|
-
'Latte\\Compiler\\Nodes\\Php\\Expression\\UndefinedsafePropertyFetchNode' => __DIR__ . '/..' . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/UndefinedsafePropertyFetchNode.php',
|
|
68
67
|
'Latte\\Compiler\\Nodes\\Php\\Expression\\VariableNode' => __DIR__ . '/..' . '/latte/latte/src/Latte/Compiler/Nodes/Php/Expression/VariableNode.php',
|
|
69
68
|
'Latte\\Compiler\\Nodes\\Php\\FilterNode' => __DIR__ . '/..' . '/latte/latte/src/Latte/Compiler/Nodes/Php/FilterNode.php',
|
|
70
69
|
'Latte\\Compiler\\Nodes\\Php\\IdentifierNode' => __DIR__ . '/..' . '/latte/latte/src/Latte/Compiler/Nodes/Php/IdentifierNode.php',
|
|
@@ -85,7 +84,6 @@ class ComposerStaticInitda1ce49ef3085539a79eddbb995629f3
|
|
|
85
84
|
'Latte\\Compiler\\Nodes\\Php\\SuperiorTypeNode' => __DIR__ . '/..' . '/latte/latte/src/Latte/Compiler/Nodes/Php/SuperiorTypeNode.php',
|
|
86
85
|
'Latte\\Compiler\\Nodes\\Php\\UnionTypeNode' => __DIR__ . '/..' . '/latte/latte/src/Latte/Compiler/Nodes/Php/UnionTypeNode.php',
|
|
87
86
|
'Latte\\Compiler\\Nodes\\Php\\VarLikeIdentifierNode' => __DIR__ . '/..' . '/latte/latte/src/Latte/Compiler/Nodes/Php/VarLikeIdentifierNode.php',
|
|
88
|
-
'Latte\\Compiler\\Nodes\\Php\\VariadicPlaceholderNode' => __DIR__ . '/..' . '/latte/latte/src/Latte/Compiler/Nodes/Php/VariadicPlaceholderNode.php',
|
|
89
87
|
'Latte\\Compiler\\Nodes\\StatementNode' => __DIR__ . '/..' . '/latte/latte/src/Latte/Compiler/Nodes/StatementNode.php',
|
|
90
88
|
'Latte\\Compiler\\Nodes\\TemplateNode' => __DIR__ . '/..' . '/latte/latte/src/Latte/Compiler/Nodes/TemplateNode.php',
|
|
91
89
|
'Latte\\Compiler\\Nodes\\TextNode' => __DIR__ . '/..' . '/latte/latte/src/Latte/Compiler/Nodes/TextNode.php',
|
|
@@ -169,15 +167,14 @@ class ComposerStaticInitda1ce49ef3085539a79eddbb995629f3
|
|
|
169
167
|
'Latte\\Runtime\\HtmlStringable' => __DIR__ . '/..' . '/latte/latte/src/Latte/Runtime/HtmlStringable.php',
|
|
170
168
|
'Latte\\Runtime\\Template' => __DIR__ . '/..' . '/latte/latte/src/Latte/Runtime/Template.php',
|
|
171
169
|
'Latte\\Sandbox\\Nodes\\FunctionCallNode' => __DIR__ . '/..' . '/latte/latte/src/Latte/Sandbox/Nodes/FunctionCallNode.php',
|
|
170
|
+
'Latte\\Sandbox\\Nodes\\FunctionCallableNode' => __DIR__ . '/..' . '/latte/latte/src/Latte/Sandbox/Nodes/FunctionCallableNode.php',
|
|
172
171
|
'Latte\\Sandbox\\Nodes\\MethodCallNode' => __DIR__ . '/..' . '/latte/latte/src/Latte/Sandbox/Nodes/MethodCallNode.php',
|
|
173
|
-
'Latte\\Sandbox\\Nodes\\
|
|
174
|
-
'Latte\\Sandbox\\Nodes\\NullsafePropertyFetchNode' => __DIR__ . '/..' . '/latte/latte/src/Latte/Sandbox/Nodes/NullsafePropertyFetchNode.php',
|
|
172
|
+
'Latte\\Sandbox\\Nodes\\MethodCallableNode' => __DIR__ . '/..' . '/latte/latte/src/Latte/Sandbox/Nodes/MethodCallableNode.php',
|
|
175
173
|
'Latte\\Sandbox\\Nodes\\PropertyFetchNode' => __DIR__ . '/..' . '/latte/latte/src/Latte/Sandbox/Nodes/PropertyFetchNode.php',
|
|
176
174
|
'Latte\\Sandbox\\Nodes\\SandboxNode' => __DIR__ . '/..' . '/latte/latte/src/Latte/Sandbox/Nodes/SandboxNode.php',
|
|
177
175
|
'Latte\\Sandbox\\Nodes\\StaticCallNode' => __DIR__ . '/..' . '/latte/latte/src/Latte/Sandbox/Nodes/StaticCallNode.php',
|
|
176
|
+
'Latte\\Sandbox\\Nodes\\StaticCallableNode' => __DIR__ . '/..' . '/latte/latte/src/Latte/Sandbox/Nodes/StaticCallableNode.php',
|
|
178
177
|
'Latte\\Sandbox\\Nodes\\StaticPropertyFetchNode' => __DIR__ . '/..' . '/latte/latte/src/Latte/Sandbox/Nodes/StaticPropertyFetchNode.php',
|
|
179
|
-
'Latte\\Sandbox\\Nodes\\UndefinedsafeMethodCallNode' => __DIR__ . '/..' . '/latte/latte/src/Latte/Sandbox/Nodes/UndefinedsafeMethodCallNode.php',
|
|
180
|
-
'Latte\\Sandbox\\Nodes\\UndefinedsafePropertyFetchNode' => __DIR__ . '/..' . '/latte/latte/src/Latte/Sandbox/Nodes/UndefinedsafePropertyFetchNode.php',
|
|
181
178
|
'Latte\\Sandbox\\RuntimeChecker' => __DIR__ . '/..' . '/latte/latte/src/Latte/Sandbox/RuntimeChecker.php',
|
|
182
179
|
'Latte\\Sandbox\\SandboxExtension' => __DIR__ . '/..' . '/latte/latte/src/Latte/Sandbox/SandboxExtension.php',
|
|
183
180
|
'Latte\\Sandbox\\SecurityPolicy' => __DIR__ . '/..' . '/latte/latte/src/Latte/Sandbox/SecurityPolicy.php',
|
|
@@ -189,7 +186,7 @@ class ComposerStaticInitda1ce49ef3085539a79eddbb995629f3
|
|
|
189
186
|
public static function getInitializer(ClassLoader $loader)
|
|
190
187
|
{
|
|
191
188
|
return \Closure::bind(function () use ($loader) {
|
|
192
|
-
$loader->classMap =
|
|
189
|
+
$loader->classMap = ComposerStaticInit19cfb30b66a778b432af39bbd1e78bca::$classMap;
|
|
193
190
|
|
|
194
191
|
}, null, ClassLoader::class);
|
|
195
192
|
}
|
|
@@ -2,17 +2,17 @@
|
|
|
2
2
|
"packages": [
|
|
3
3
|
{
|
|
4
4
|
"name": "latte/latte",
|
|
5
|
-
"version": "v3.0.
|
|
6
|
-
"version_normalized": "3.0.
|
|
5
|
+
"version": "v3.0.2",
|
|
6
|
+
"version_normalized": "3.0.2.0",
|
|
7
7
|
"source": {
|
|
8
8
|
"type": "git",
|
|
9
9
|
"url": "https://github.com/nette/latte.git",
|
|
10
|
-
"reference": "
|
|
10
|
+
"reference": "c3eee2e4e2c21cdf9f9c158c4bfa6150625457e1"
|
|
11
11
|
},
|
|
12
12
|
"dist": {
|
|
13
13
|
"type": "zip",
|
|
14
|
-
"url": "https://api.github.com/repos/nette/latte/zipball/
|
|
15
|
-
"reference": "
|
|
14
|
+
"url": "https://api.github.com/repos/nette/latte/zipball/c3eee2e4e2c21cdf9f9c158c4bfa6150625457e1",
|
|
15
|
+
"reference": "c3eee2e4e2c21cdf9f9c158c4bfa6150625457e1",
|
|
16
16
|
"shasum": ""
|
|
17
17
|
},
|
|
18
18
|
"require": {
|
|
@@ -37,7 +37,7 @@
|
|
|
37
37
|
"nette/php-generator": "to use tag {templatePrint}",
|
|
38
38
|
"nette/utils": "to use filter |webalize"
|
|
39
39
|
},
|
|
40
|
-
"time": "2022-06-
|
|
40
|
+
"time": "2022-06-15T13:42:57+00:00",
|
|
41
41
|
"bin": [
|
|
42
42
|
"bin/latte-lint"
|
|
43
43
|
],
|
|
@@ -83,7 +83,7 @@
|
|
|
83
83
|
],
|
|
84
84
|
"support": {
|
|
85
85
|
"issues": "https://github.com/nette/latte/issues",
|
|
86
|
-
"source": "https://github.com/nette/latte/tree/v3.0.
|
|
86
|
+
"source": "https://github.com/nette/latte/tree/v3.0.2"
|
|
87
87
|
},
|
|
88
88
|
"install-path": "../latte/latte"
|
|
89
89
|
}
|
|
@@ -1,31 +1,31 @@
|
|
|
1
1
|
<?php return array(
|
|
2
2
|
'root' => array(
|
|
3
|
-
'name' => '__root__',
|
|
4
3
|
'pretty_version' => 'dev-main',
|
|
5
4
|
'version' => 'dev-main',
|
|
6
|
-
'reference' => '4b13b1e1b01461c4060434ea2362d03de525c3ea',
|
|
7
5
|
'type' => 'library',
|
|
8
6
|
'install_path' => __DIR__ . '/../../',
|
|
9
7
|
'aliases' => array(),
|
|
8
|
+
'reference' => '9a94a0fa929e1b024d24966cf6da1840000cfa40',
|
|
9
|
+
'name' => '__root__',
|
|
10
10
|
'dev' => true,
|
|
11
11
|
),
|
|
12
12
|
'versions' => array(
|
|
13
13
|
'__root__' => array(
|
|
14
14
|
'pretty_version' => 'dev-main',
|
|
15
15
|
'version' => 'dev-main',
|
|
16
|
-
'reference' => '4b13b1e1b01461c4060434ea2362d03de525c3ea',
|
|
17
16
|
'type' => 'library',
|
|
18
17
|
'install_path' => __DIR__ . '/../../',
|
|
19
18
|
'aliases' => array(),
|
|
19
|
+
'reference' => '9a94a0fa929e1b024d24966cf6da1840000cfa40',
|
|
20
20
|
'dev_requirement' => false,
|
|
21
21
|
),
|
|
22
22
|
'latte/latte' => array(
|
|
23
|
-
'pretty_version' => 'v3.0.
|
|
24
|
-
'version' => '3.0.
|
|
25
|
-
'reference' => '1eee22c760ab8d028e2c21f87fbb7ef7bfeaa0b5',
|
|
23
|
+
'pretty_version' => 'v3.0.2',
|
|
24
|
+
'version' => '3.0.2.0',
|
|
26
25
|
'type' => 'library',
|
|
27
26
|
'install_path' => __DIR__ . '/../latte/latte',
|
|
28
27
|
'aliases' => array(),
|
|
28
|
+
'reference' => 'c3eee2e4e2c21cdf9f9c158c4bfa6150625457e1',
|
|
29
29
|
'dev_requirement' => false,
|
|
30
30
|
),
|
|
31
31
|
),
|
|
@@ -20,25 +20,16 @@ class FunctionCallNode extends ExpressionNode
|
|
|
20
20
|
{
|
|
21
21
|
public function __construct(
|
|
22
22
|
public NameNode|ExpressionNode $name,
|
|
23
|
-
/** @var array<Php\ArgumentNode
|
|
23
|
+
/** @var array<Php\ArgumentNode> */
|
|
24
24
|
public array $args = [],
|
|
25
25
|
public ?Position $position = null,
|
|
26
26
|
) {
|
|
27
|
-
(function (Php\ArgumentNode
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
public function isFirstClassCallable(): bool
|
|
32
|
-
{
|
|
33
|
-
return ($this->args[0] ?? null) instanceof Php\VariadicPlaceholderNode;
|
|
27
|
+
(function (Php\ArgumentNode ...$args) {})(...$args);
|
|
34
28
|
}
|
|
35
29
|
|
|
36
30
|
|
|
37
31
|
public function print(PrintContext $context): string
|
|
38
32
|
{
|
|
39
|
-
if (PHP_VERSION_ID < 80100 && $this->isFirstClassCallable()) {
|
|
40
|
-
return $context->memberAsString($this->name);
|
|
41
|
-
}
|
|
42
33
|
return $context->callExpr($this->name)
|
|
43
34
|
. '(' . $context->implode($this->args) . ')';
|
|
44
35
|
}
|