Bruno Kolenbrander

Results 76 comments of Bruno Kolenbrander

Do we want to deprecate+remove the alias `pub type PyObject = Py;`? I don't like it very much, and removing it should probably be done before 1.0

> I'm unsure if this is something we should aim to fix I think so yes. I would be really surprised if I wrote: ```rust #[pymethods] impl MyClass { #[classattr]...

We could set `tp_setattro` on the type object to point to a function that just returns an error.

> Can you overwrite methods from `pymethods` by reassigning them on the class? If yes, I don't see why class attrs are different. Yes

Right. So this means we effectively have to support metaclasses?

On Python < 3.10, we can set this inside `create_type_object_impl`: ```rust unsafe extern "C" fn error_setattrofunc(_slf: *mut ffi::PyObject, _attr: *mut ffi::PyObject, _value: *mut ffi::PyObject) -> c_int { let py =...

> Monkey-patching methods and attributes is a fact of life in Python, and oftentimes even helpful. I think that largely depends on perspective. It's certainly nice when you, as a...

Thank you for the review. I have: - formatted the tests - moved `primitive_sym` to a method on `rustc_middle::ty::Ty` - (not your feedback but) changed the `Similar` enum to use...