[BUG][FIX?] 1908PrintArrayFix

Stephan Rudlof sr at evolgo.de
Mon Mar 13 15:37:45 UTC 2000


Stefan (sma),

I have problems with your

1908PrintArrayFix-sma -- Stefan Matthias Aust -- 3 March 2000
Teamwork: Russell Swan noticed a bug, Bert Freudenberg suggested a fix
and I implemented it.
Actually, this became a complete pretty printing and refactoring of the
plugin. I added a var:type:
method which reduced the need to repeat the varName in var:declareC: and
always because this is both
error-prone and space consuming."

changeset.

Following method seems to be incorrect and has to be corrected as shown
at the end.
---
IntegerPlugin class >>
declareCVarsIn: aCCodeGenerator
	"Note: This method must be implemented by all subclasses to declare
variables."

	aCCodeGenerator var: #interpreterProxy type: #'struct VirtualMachine*'
---


This doesn't generate the correct var declaration for #interpreterProxy
in my LargeInteger plugin source.
The same effect arises while compiling the KlattSynthesizerPlugin, so
this seems to be a problem outside of my plugin: Mixing symbols and
strings could be the origin of the problems... The other vars declared
for the KlattSynthesizerPlugin,
---
declareCVarsIn: cg 
	cg var: #resonators type: #'float*'.
	cg var: #frame type: #'float*'.
	cg var: #pitch type: #float.
	cg var: #a1 type: #float.
	cg var: #a2 type: #float.
	cg var: #x1 type: #float.
	cg var: #x2 type: #float.
	cg var: #b1 type: #float.
	cg var: #c1 type: #float.
	cg var: #glast type: #float.
	cg var: #vlast type: #float.
	cg var: #nlast type: #float
---
only appear as ints in the plugin source! Please take a look onto the
generated plugin source...

Greetings,

Stephan (sr)

Fix (sufficient for me, but what's with the other plugins?):

'From Squeak2.8alpha of 7 February 2000 [latest update: #1919] on 13
March 2000 at 4:21:20 pm'!

!InterpreterPlugin class methodsFor: 'translation' stamp: 'sr 3/13/2000
16:09'!
declareCVarsIn: aCCodeGenerator
	"Note: This method must be implemented by all subclasses to declare
variables."

	aCCodeGenerator var: 'interpreterProxy' type: 'struct VirtualMachine*'!
!





More information about the Squeak-dev mailing list