weixin_39611506 2020-11-22 04:07
浏览 0

Type guards with nullable return types

Describe the bug It's a bit hard to explain, so adding a code example below.

Screenshot 2019-12-05 at 16 20 43

Causes Error: Expected type 'string'. Found 'null|string'. intelephense(1006)

Expected behavior Since I make sure both variables are not not null, I expect to see no errors.

Platform and version Mac OS and Intelephense 1.3.1.

该提问来源于开源项目:bmewburn/vscode-intelephense

  • 写回答

0条回答 默认 最新

    报告相同问题?