# Changeset 3011:309190c27a02

Ignore:
Timestamp:
02/17/07 21:43:55 (6 years ago)
Branch:
default
Children:
3021:5df601546772, 3958:cbf23a4344e8
Message:

Fix is_FiniteFieldElement.

Location:
sage
Files:
4 edited

Unmodified
Removed
• ## sage/rings/all.py

 r2969 from finite_field import (FiniteField, is_FiniteField, GF, conway_polynomial, exists_conway_polynomial) from finite_field_element import FiniteFieldElement from finite_field_element import FiniteFieldElement, is_FiniteFieldElement # Number field
• ## sage/rings/finite_field_element.py

 r3010 EXAMPLE: sage: is_FiniteFieldElement(1) False False sage: is_FiniteFieldElement(IntegerRing()) False False sage: is_FiniteFieldElement(GF(5)(2)) True True sage: is_FiniteFieldElement(GF(25,'a')(2)) True """ # This stupid thing is needed because GF(5)(2) gives an # integer mod 5, and ints mod don't derive from FiniteFieldElement. return isinstance(x, element.Element) and ring.is_FiniteField(x.parent()) #return isinstance(x, FiniteFieldElement) class FiniteField_ext_pariElement(FiniteFieldElement):
• ## sage/structure/all.py

 r2147 is_EuclideanDomainElement, is_FieldElement, is_FiniteFieldElement, is_InfinityElement, is_IntegralDomainElement,
• ## sage/structure/element.pyx

 r2874 return self/right, 0 def is_FiniteFieldElement(x): """ Return True if x is of type FiniteFieldElement. """ return IS_INSTANCE(x, FiniteFieldElement) ## def is_FiniteFieldElement(x): ##     """ ##     Return True if x is of type FiniteFieldElement. ##     """ ##     return IS_INSTANCE(x, FiniteFieldElement) cdef class FiniteFieldElement(FieldElement):
Note: See TracChangeset for help on using the changeset viewer.