ArrayWrites.java
/**
* Copyright 2010,2021 Nikolas S Boyd.
Permission is granted to copy this work provided this copyright statement is retained in all copies.
*/
package Hoot.Tests;
import Hoot.Runtime.Functions.*;
import Hoot.Runtime.Faces.*;
import Hoot.Runtime.Values.*;
import Hoot.Runtime.Blocks.*;
import Smalltalk.Core.*;
import Smalltalk.Blocks.*;
import Smalltalk.Magnitudes.*;
import Hoot.Behaviors.*;
import Hoot.Behaviors.Nil;
import Hoot.Behaviors.Object;
import Hoot.Behaviors.True;
import Hoot.Behaviors.False;
import Hoot.Behaviors.Boolean;
import Hoot.Magnitudes.*;
import Hoot.Magnitudes.Integer;
import Hoot.Magnitudes.Character;
import Hoot.Magnitudes.Float;
import Hoot.Magnitudes.Double;
import Hoot.Collections.*;
import Hoot.Collections.String;
import static Hoot.Magnitudes.SmallInteger.*;
public class ArrayWrites extends TestableClosure
{
protected static final Array CachedInts = ((Array)Array.withAll(new Object[]{
SmallInteger.from(1), SmallInteger.from(2), SmallInteger.from(3), SmallInteger.from(4), SmallInteger.from(5), SmallInteger.from(6), SmallInteger.from(7), SmallInteger.from(8), SmallInteger.from(9), SmallInteger.from(10)
}));
protected Array array = Array.type().$new(SmallInteger.from(10));
/**
* @return
*/
@Override public String description()
{
java.lang.String exitID = "ArrayWrites>>description";
Frame f0 = new Frame(exitID);
return (String)String.from("Array writes");
}
/**
* @return
*/
@Override public void runTest()
{
java.lang.String exitID = "ArrayWrites>>runTest";
Frame f0 = new Frame(exitID);
{
Array prime = (Array)array;
prime.at_put(SmallInteger.from(1), Zero);
prime.at_put(SmallInteger.from(2), Zero);
prime.at_put(SmallInteger.from(3), Zero);
prime.at_put(SmallInteger.from(4), Zero);
prime.at_put(SmallInteger.from(5), Zero);
prime.at_put(SmallInteger.from(6), Zero);
prime.at_put(SmallInteger.from(7), Zero);
prime.at_put(SmallInteger.from(8), Zero);
prime.at_put(SmallInteger.from(9), Zero);
prime.at_put(SmallInteger.from(10), Zero);
};
}
}