Author: Armin Rigo <ar...@tunes.org> Branch: Changeset: r92418:a9eafbdf3c28 Date: 2017-09-19 12:13 +0200 http://bitbucket.org/pypy/pypy/changeset/a9eafbdf3c28/
Log: merge heads diff --git a/pypy/doc/windows.rst b/pypy/doc/windows.rst --- a/pypy/doc/windows.rst +++ b/pypy/doc/windows.rst @@ -120,7 +120,7 @@ Download the versions of all the external packages from https://bitbucket.org/pypy/pypy/downloads/local_59.zip (for post-5.8 builds) with sha256 checksum -``0f96c045db1f5f73ad0fae7857caa69c261324bd8e51f6d2ad1fa842c4a5f26f`` +``6344230e90ab7a9cb84efbae1ba22051cdeeb40a31823e0808545b705aba8911`` https://bitbucket.org/pypy/pypy/downloads/local_5.8.zip (to reproduce 5.8 builds) with sha256 checksum ``fbe769bf3a4ab6f5a8b0a05b61930fc7f37da2a9a85a8f609cf5a9bad06e2554`` or diff --git a/pypy/module/cpyext/methodobject.py b/pypy/module/cpyext/methodobject.py --- a/pypy/module/cpyext/methodobject.py +++ b/pypy/module/cpyext/methodobject.py @@ -109,21 +109,27 @@ return self.space.unwrap(self.descr_method_repr()) def descr_method_repr(self): + w_objclass = self.w_objclass + assert isinstance(w_objclass, W_TypeObject) return self.space.newtext("<method '%s' of '%s' objects>" % ( - self.name, self.w_objclass.getname(self.space))) + self.name, w_objclass.name)) def descr_call(self, space, __args__): args_w, kw_w = __args__.unpack() if len(args_w) < 1: + w_objclass = self.w_objclass + assert isinstance(w_objclass, W_TypeObject) raise oefmt(space.w_TypeError, "descriptor '%s' of '%s' object needs an argument", - self.name, self.w_objclass.getname(self.space)) + self.name, w_objclass.name) w_instance = args_w[0] # XXX: needs a stricter test if not space.isinstance_w(w_instance, self.w_objclass): + w_objclass = self.w_objclass + assert isinstance(w_objclass, W_TypeObject) raise oefmt(space.w_TypeError, "descriptor '%s' requires a '%s' object but received a '%T'", - self.name, self.w_objclass.getname(self.space), w_instance) + self.name, w_objclass.name, w_instance) w_args = space.newtuple(args_w[1:]) w_kw = space.newdict() for key, w_obj in kw_w.items(): diff --git a/pypy/module/sys/__init__.py b/pypy/module/sys/__init__.py --- a/pypy/module/sys/__init__.py +++ b/pypy/module/sys/__init__.py @@ -91,13 +91,14 @@ 'float_info' : 'system.get_float_info(space)', 'long_info' : 'system.get_long_info(space)', 'float_repr_style' : 'system.get_float_repr_style(space)', - 'getdlopenflags' : 'system.getdlopenflags', - 'setdlopenflags' : 'system.setdlopenflags', } if sys.platform == 'win32': interpleveldefs['winver'] = 'version.get_winver(space)' interpleveldefs['getwindowsversion'] = 'vm.getwindowsversion' + else: + interpleveldefs['getdlopenflags'] = 'system.getdlopenflags' + interpleveldefs['setdlopenflags'] = 'system.setdlopenflags' appleveldefs = { 'excepthook' : 'app.excepthook', _______________________________________________ pypy-commit mailing list pypy-commit@python.org https://mail.python.org/mailman/listinfo/pypy-commit