Opened 12 years ago

Closed 9 years ago

#1135 closed defect (fixed)

Error in preparsing generators, QuadraticField

Reported by: ncalexan Owned by: ncalexan
Priority: major Milestone: sage-4.6
Component: number fields Keywords: preparse generators QuadraticField
Cc: Merged in: sage-4.6.alpha2
Authors: Luis Felipe Tabera Alonso Reviewers: Nick Alexander
Report Upstream: N/A Work issues:
Branch: Commit:
Dependencies: Stopgaps:

Description

sage: K.<a> = QuadraticField(-55, 'a')
---------------------------------------------------------------------------
<type 'exceptions.TypeError'>             Traceback (most recent call last)

/Users/ncalexan/emacs/<ipython console> in <module>()

<type 'exceptions.TypeError'>: QuadraticField() got multiple values for keyword argument 'names'

Attachments (1)

trac-1135.patch (2.8 KB) - added by lftabera 9 years ago.

Download all attachments as: .zip

Change History (6)

comment:1 Changed 12 years ago by mabshoff

  • Milestone changed from sage-2.11 to sage-2.9.1

comment:2 Changed 10 years ago by davidloeffler

  • Component changed from interfaces to number fields
  • Report Upstream set to N/A

This clearly belongs in "number fields" ("interfaces" is for Sage interfaces to other software, not for user-interface issues).

Changed 9 years ago by lftabera

comment:3 Changed 9 years ago by lftabera

  • Authors set to Luis Felipe Tabera Alonso
  • Status changed from new to needs_review

This is a small error that is embarrasingly old. This patch solves the problem. You can use a generator name and the preparser in all combinations.

  • I have added a default name for the generator 'a' to be consistent with NumberField?.
  • I have documented the behaviour of Sage when QuadraticField? and NumberField? are given two generators but there is a conflict in their names. The generator name given by the preparser has precedence in this case.

comment:4 Changed 9 years ago by ncalexan

  • Reviewers set to Nick Alexander
  • Status changed from needs_review to positive_review

Looks fine to me and passes tests on sage.math. Positive review!

comment:5 Changed 9 years ago by mpatel

  • Merged in set to sage-4.6.alpha2
  • Resolution set to fixed
  • Status changed from positive_review to closed
Note: See TracTickets for help on using tickets.