Ticket #14158: 14158_is_field_except.patch

File 14158_is_field_except.patch, 836 bytes (added by jdemeyer, 9 years ago)
  • sage/rings/ring.pxd

    # HG changeset patch
    # User Jeroen Demeyer <jdemeyer@cage.ugent.be>
    # Date 1361785355 -3600
    # Node ID 31d4341b32cc4191638967f2d0bfac70ce94a5da
    # Parent  a104458275e71f8c45dc3f8729e22659981598ec
    _is_Field() should not ignore exceptions
    
    diff --git a/sage/rings/ring.pxd b/sage/rings/ring.pxd
    a b  
    11from sage.structure.parent_gens cimport ParentWithGens
    22
    3 cpdef bint _is_Field(x)
     3cpdef bint _is_Field(x) except -2
    44
    55cdef class Ring(ParentWithGens):
    66    cdef public object _zero_element
  • sage/rings/ring.pyx

    diff --git a/sage/rings/ring.pyx b/sage/rings/ring.pyx
    a b  
    20092009       """
    20102010        raise NotImplementedError
    20112011
    2012 cpdef bint _is_Field(x):
     2012cpdef bint _is_Field(x) except -2:
    20132013    """
    20142014    Return True if x is a field.
    20152015