Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

broken real number exponent preparsing #4806

Closed
sagetrac-dmharvey mannequin opened this issue Dec 15, 2008 · 1 comment
Closed

broken real number exponent preparsing #4806

sagetrac-dmharvey mannequin opened this issue Dec 15, 2008 · 1 comment

Comments

@sagetrac-dmharvey
Copy link
Mannequin

sagetrac-dmharvey mannequin commented Dec 15, 2008

In sage 3.2:

sage: 1.656e02
165.600000000000      # ok
sage: 1.656e-02
0.0165600000000000     # ok
sage: 1.656e+02
---------------------------------------------------------------------------
TypeError                                 Traceback (most recent call last)

/Users/david/<ipython console> in <module>()

/Users/david/sage-3.2/local/lib/python2.5/site-packages/sage/rings/real_mpfr.so in sage.rings.real_mpfr.create_RealNumber (sage/rings/real_mpfr.c:21490)()

/Users/david/sage-3.2/local/lib/python2.5/site-packages/sage/rings/real_mpfr.so in sage.rings.real_mpfr.RealLiteral.__init__ (sage/rings/real_mpfr.c:20706)()

/Users/david/sage-3.2/local/lib/python2.5/site-packages/sage/rings/real_mpfr.so in sage.rings.real_mpfr.RealNumber.__init__ (sage/rings/real_mpfr.c:7305)()

/Users/david/sage-3.2/local/lib/python2.5/site-packages/sage/rings/real_mpfr.so in sage.rings.real_mpfr.RealNumber._set (sage/rings/real_mpfr.c:7782)()

TypeError: Unable to convert x (='1.656e') to real number.

In plain python 2.5.2:

>>> 1.656e+02
165.59999999999999

Component: user interface

Issue created by migration from https://trac.sagemath.org/ticket/4806

@sagetrac-mabshoff sagetrac-mabshoff mannequin added this to the sage-3.2.2 milestone Dec 15, 2008
@boothby
Copy link

boothby commented Jan 23, 2009

comment:2

Rolled into #5079

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants