We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ab712c7 commit 9bf58b8Copy full SHA for 9bf58b8
src/sage/interfaces/macaulay2.py
@@ -656,16 +656,14 @@ def cputime(self, t=None):
656
657
def version(self):
658
"""
659
- Returns the version of Macaulay2.
+ Return the version of Macaulay2 as a tuple.
660
661
EXAMPLES::
662
663
sage: macaulay2.version() # optional - macaulay2
664
- (1, 1...
+ (1, ...)
665
666
- s = self.eval("version")
667
- r = re.compile("VERSION => (.*?)\n")
668
- s = r.search(s).groups()[0]
+ s = self.eval('version#"VERSION"')
669
return tuple(int(i) for i in s.split("."))
670
671
# Constructors
0 commit comments