File tree 2 files changed +12
-4
lines changed
src/Symfony/Component/ExpressionLanguage
2 files changed +12
-4
lines changed Original file line number Diff line number Diff line change @@ -137,6 +137,14 @@ public function testCachingForOverriddenVariableNames()
137
137
$ this ->assertSame ('($a + $B) ' , $ result );
138
138
}
139
139
140
+ public function testStrictEquality ()
141
+ {
142
+ $ expressionLanguage = new ExpressionLanguage ();
143
+ $ expression = '123 === a ' ;
144
+ $ result = $ expressionLanguage ->compile ($ expression , array ('a ' ));
145
+ $ this ->assertSame ('(123 === $a) ' , $ result );
146
+ }
147
+
140
148
public function testCachingWithDifferentNamesOrder ()
141
149
{
142
150
$ cacheMock = $ this ->getMockBuilder ('Psr\Cache\CacheItemPoolInterface ' )->getMock ();
Original file line number Diff line number Diff line change @@ -30,11 +30,11 @@ class Token
30
30
const PUNCTUATION_TYPE = 'punctuation ' ;
31
31
32
32
/**
33
- * @param string $type The type of the token (self::*_TYPE)
34
- * @param string $value The token value
35
- * @param int $cursor The cursor position in the source
33
+ * @param string $type The type of the token (self::*_TYPE)
34
+ * @param string|int|float $value The token value
35
+ * @param int $cursor The cursor position in the source
36
36
*/
37
- public function __construct (string $ type , ? string $ value , ?int $ cursor )
37
+ public function __construct (string $ type , $ value , ?int $ cursor )
38
38
{
39
39
$ this ->type = $ type ;
40
40
$ this ->value = $ value ;
You can’t perform that action at this time.
0 commit comments