extField from RationalPoints2 overtakes symbol "a"
Nobody has claimed this yet.
- Dominant language
- Macaulay2
- Stars
- 435
- Forks
- 297
- Avg merge
- 4d 20h
- Merged PRs (30d)
- 11
Description
The documentation warns:
> **N.B. Any data previously stored in this symbol will be lost!** As is the case for GaloisField.
I think this behavior, which is caused by calling `getSymbol`, should be fixed in GF as well and discouraged in other packages. Here is what can happen:
```m2
i1 : needsPackage "RationalPoints2";
i2 : R = QQ[a,b];
i3 : T = ZZ/2[t];
i4 : extField { t^2+t+1 }
o4 = GF 4
o4 : GaloisField
i5 : a
o5 = a
o5 : GF 4
```
The problem is that a call to `extField` could be happening somewhere deep in an algorithm, and consequently "a" will be taken over without the user knowing where it happened.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by tracing extField and getSymbol in GaloisField and RationalPoints2, reproducing the provided example to identify where symbol "a" is replaced. Done should prevent an unexpected overwrite in GF and establish how similar behavior is discouraged in other packages.
Written by the indexing model from the issue text.
Assessment
- Domain
- tooling
- Issue type
- Bug
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100