代码之家  ›  专栏  ›  技术社区  ›  Imran

hasattr()vs try except块处理不存在的属性

  •  74
  • Imran  · 技术社区  · 15 年前
    内容过于久远,请刷新稍后重试
    12 回复  |  直到 15 年前
        1
  •  91
  •   Pierre.Vriens Krzysztof J    8 年前
        2
  •  85
  •   Alex Martelli    15 年前
        3
  •  29
  •   Community CDub    7 年前
        4
  •  19
  •   Martin Geisler    11 年前
        5
  •  13
  •   Roee Adler    15 年前
        6
  •  5
  •   UncleZeiv    15 年前
        7
  •  5
  •   Community CDub    4 年前
        8
  •  4
  •   n8gray    15 年前
        9
  •  3
  •   Douglas Leeder    15 年前
        10
  •  2
  •   cjs    15 年前
        11
  •  0
  •   Unknown    15 年前
        12
  •  0
  •   Levite    12 年前