We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent eea5240 commit bd20ad2Copy full SHA for bd20ad2
tools/generator.php
@@ -4,7 +4,10 @@
4
$const = array();
5
6
while ($row = fgets(STDIN)) {
7
- if (preg_match('/^([0-9A-Z]{5}) +[SWE] +[^ ]+? +([a-z_]+)$/', $row, $matches)) {
+ if (preg_match('/^Section: (Class .*)$/', $row, $matches)) {
8
+ $const[] = '';
9
+ $const[] = " // {$matches[1]}";
10
+ } elseif (preg_match('/^([0-9A-Z]{5}) +[SWE] +[^ ]+? +([a-z_]+)$/', $row, $matches)) {
11
$key = strtoupper($matches[2]);
12
if (isset($codes[$key])) {
13
$key .= '_EXCEPTION';
@@ -14,7 +17,7 @@
14
17
}
15
18
16
19
-$const = implode(PHP_EOL, $const);
20
+$const = trim(implode(PHP_EOL, $const), PHP_EOL);
21
22
echo <<<EOD
23
<?php
0 commit comments