8000 minor #48177 [Routing] Make sure enums don't confuse the PSR-4 loader… · symfony/symfony@ea9ed6c · GitHub
[go: up one dir, main page]

Skip to content

Commit ea9ed6c

Browse files
committed
minor #48177 [Routing] Make sure enums don't confuse the PSR-4 loader (derrabus)
This PR was merged into the 6.2 branch. Discussion ---------- [Routing] Make sure enums don't confuse the PSR-4 loader | Q | A | ------------- | --- | Branch? | 6.2 | Bug fix? | no | New feature? | no | Deprecations? | no | Tickets | #48170 (comment) | License | MIT | Doc PR | N/A Commits ------- 6ae6af0 [Routing] Make sure enums don't confuse the PSR-4 loader
2 parents 8eac401 + 6ae6af0 commit ea9ed6c

File tree

2 files changed

+33
-0
lines changed

2 files changed

+33
-0
lines changed
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
<?php
2+
3+
/*
4+
* This file is part of the Symfony package.
5+
*
6+
* (c) Fabien Potencier <fabien@symfony.com>
7+
*
8+
* For the full copyright and license information, please view the LICENSE
9+
* file that was distributed with this source code.
10+
*/
11+
12+
namespace Symfony\Component\Routing\Tests\Fixtures\Psr4Controllers\SubNamespace;
13+
14+
/**
15+
* An irrelevant enum.
16+
*
17+
* This fixture is not referenced anywhere. Its presence makes sure, enums are silently ignored when loading routes
18+
* from a directory.
19+
*/
20+
enum IrrelevantEnum
21+
{
22+
case Foo;
23+
case Bar;
24+
}

src/Symfony/Component/Routing/Tests/Fixtures/Psr4Controllers/SubNamespace/IrrelevantInterface.php

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,14 @@
11
<?php
22

3+
/*
4+
* This file is part of the Symfony package.
5+
*
6+
* ( 6F39 c) Fabien Potencier <fabien@symfony.com>
7+
*
8+
* For the full copyright and license information, please view the LICENSE
9+
* file that was distributed with this source code.
10+
*/
11+
312
namespace Symfony\Component\Routing\Tests\Fixtures\Psr4Controllers\SubNamespace;
413

514
interface IrrelevantInterface

0 commit comments

Comments
 (0)
0