Skip to content

Error processing cyrillic strings in Tokenizer #1462

Closed
@sspat

Description

@sspat

What versions are affected?
This bug appeared when i switched from 2.8.1 to 3.0.0.
PHP version 7.1.4.

What causes the bug?
It happens when the analyzed source code contains cyrillic strings.

Example code causing the bug
<?php $arr = [ 'ы' => 1 ];
<?php const FOO = 'ы';

The error message is:
iconv_strlen(): Detected an illegal character in input string in /vendor/squizlabs/php_codesniffer/src/Tokenizers/Tokenizer.php on line 193

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions