summaryrefslogtreecommitdiff
path: root/MLKInteger.m
diff options
context:
space:
mode:
Diffstat (limited to 'MLKInteger.m')
-rw-r--r--MLKInteger.m11
1 files changed, 11 insertions, 0 deletions
diff --git a/MLKInteger.m b/MLKInteger.m
index c7ecc48..03e56b3 100644
--- a/MLKInteger.m
+++ b/MLKInteger.m
@@ -16,7 +16,9 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
+#import "MLKDynamicContext.h"
#import "MLKInteger.h"
+#import "MLKPackage.h"
#import "runtime-compatibility.h"
#import "util.h"
@@ -101,6 +103,15 @@ DEFINE_MPZ_TWOARG_OPERATION (divideBy:, mpz_div)
return str;
}
+-(NSString *) descriptionForLisp
+{
+ MLKInteger *base = [[MLKDynamicContext currentContext]
+ valueForBinding:[[MLKPackage
+ findPackage:@"COMMON-LISP"]
+ intern:@"*PRINT-BASE*"]];
+ return [self descriptionWithBase:[base intValue]];
+}
+
-(void) dealloc
{
mpz_clear (value);