aboutsummaryrefslogtreecommitdiff
blob: 9b5b4d114461d8ead8008e910148a622dc7c7d21 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
"""
  None Object implementation

  ok and tested
""" 

from pypy.objspace.std.objspace import *

class W_NoneObject(W_Object):
    from pypy.objspace.std.nonetype import none_typedef as typedef
registerimplementation(W_NoneObject)

def unwrap__None(space, w_none):
    return None

def nonzero__None(space, w_none):
    return space.w_False

def repr__None(space, w_none):
    return space.wrap('None')

register_all(vars())