Code Inspection: Invalid string offset usage
Configure inspections: Settings | Editor | Inspections
Show intention actions: AltEnter
Reports invalid string offset usages that will result in a runtime error.
The following usages are reported:
Using string offsets as objects or arrays
Unsetting string offsets via
unset
Passing string offsets by reference
Creating references to or from string offsets
Incrementing or decrementing string offsets
Using combined operator assignments such as
+=
or.=
on string offsetsAssigning string offsets with empty strings or strings with length >1
Place the caret at the highlighted line and press AltEnter or click
.
Click the arrow next to the inspection you want to suppress and select the necessary suppress action.