Skip to content

TP0201

Error: undefined name

  • undefined name '<x>' (with help use 'None' for none)
  • undefined type '<T>'
  • module '<m>' has no definition '<x>'
  • .NET namespace '<ns>' has no type '<x>' (M21)

From the golden case tests/cases/m13/tp0201_is_none.tpn:

tp0201_is_none.tpn
let a: int? = None
if a is none:
pass

The compiler reports:

tp0201_is_none.tpn:2:9: error TP0201: undefined name 'none'
help: use 'None'

The specification lists every code.