Mantis Bugtracker
  

Viewing Issue Advanced Details Jump to Notes ] View Simple ] Issue History ] Print ]
ID Category Severity Reproducibility Date Submitted Last Update
0006697 [Squeak] Kernel minor N/A 09-25-07 00:25 04-18-10 22:04
Reporter nicolas cellier View Status public  
Assigned To andreas
Priority normal Resolution fixed Platform
Status closed   OS
Projection none   OS Version
ETA none Fixed in Version trunk Product Version 3.10
  Product Build
Summary 0006697: Number>>storeOn:base: default implementation is wrong
Description It calls printOn:base:
But modern definition of printOn:base: don't print the radix prefix.
While storeOn:base: should.

This is one cause of http://bugs.squeak.org/view.php?id=6695 [^]

Since the storeOn:base: method is defined in every subclass where relevant
(except ScaledDecimal see http://bugs.squeak.org/view.php?id=6696), [^] I strongly suggest to implement self subclassResponsibility in Number like printOn:base:
Steps To Reproduce
Additional Information
Don't expect a test case for this bug. It is quite trivial and virtual, because it is in an abstract class and it is overriden in subclasses. But it is a bug. To show it, one need to define a new Number class defining just printOn:base: but not storeOn:base: SUPER-HEAVY-NONSENSE
Attached Files  NumberStoreOnBase-M6697-Patch.1.cs [^] (617 bytes) 09-25-07 00:30

- Relationships
related to 0006695closed andreas Float storeStringBase: does not store the radix 
related to 0006696assigned andreas ScaledDecimal can read in base 16 but cannot print in base 16 

- Notes
(0011197 - 45 - 45 - 45 - 45 - 45 - 45)
nicolas cellier
09-25-07 00:31

The patch also add a comment to printOn:base:
 
(0011199 - 272 - 320 - 320 - 320 - 320 - 320)
nicolas cellier
09-25-07 00:57
edited on: 09-25-07 01:09

In 3.8 the code was correct because printOn:base: USED TO print the radix prefix

Who ever made the change SHOULD have taken care of all implementors and senders.

Was it a good decision anyway?
Standard compliant?
Has it been discussed in squeak-dev or somewhere?

 
(0011567 - 94 - 138 - 138 - 138 - 138 - 138)
Keith_Hodges
12-17-07 17:26
edited on: 01-18-08 09:40

"fix begin"
Installer mantis bug: 6697 fix:'NumberStoreOnBase-M6697-Patch.1.cs'.
"fix end"

 
(0013330 - 60 - 66 - 216 - 216 - 216 - 216)
nicolas cellier
10-04-09 17:56

Fixed in
http://source.squeak.org/trunk/Kernel-nice.255.mcz [^]
 

- Issue History
Date Modified Username Field Change
09-25-07 00:25 nicolas cellier New Issue
09-25-07 00:30 nicolas cellier File Added: NumberStoreOnBase-M6697-Patch.1.cs
09-25-07 00:31 nicolas cellier Note Added: 0011197
09-25-07 00:57 nicolas cellier Note Added: 0011199
09-25-07 01:09 nicolas cellier Note Edited: 0011199
09-25-07 01:20 matthewf Relationship added related to 0006696
12-17-07 17:26 Keith_Hodges Note Added: 0011567
12-17-07 17:32 Keith_Hodges Note Edited: 0011567
01-18-08 09:39 Keith_Hodges Note Edited: 0011567
01-18-08 09:40 Keith_Hodges Note Edited: 0011567
01-10-09 02:00 Keith_Hodges Status new => pending
01-10-09 03:32 Keith_Hodges Status pending => testing
01-10-09 03:39 Keith_Hodges Status testing => resolved
01-10-09 03:39 Keith_Hodges Fixed in Version  => 3.11
01-10-09 03:39 Keith_Hodges Resolution open => fixed
01-10-09 03:39 Keith_Hodges Assigned To  => Keith_Hodges
01-10-09 03:41 Keith_Hodges Status resolved => testing
10-03-09 19:34 Keith_Hodges Status testing => assigned
10-03-09 19:34 Keith_Hodges Assigned To Keith_Hodges => andreas
10-04-09 17:54 nicolas cellier Relationship added related to 0006695
10-04-09 17:56 nicolas cellier Status assigned => resolved
10-04-09 17:56 nicolas cellier Fixed in Version 3.11 => trunk
10-04-09 17:56 nicolas cellier Note Added: 0013330
04-18-10 22:04 andreas Status resolved => closed


Mantis 1.0.8[^]
Copyright © 2000 - 2007 Mantis Group
81 total queries executed.
43 unique queries executed.
Powered by Mantis Bugtracker