<?php 

$test = new BugTest();

echo "Before Setting: ";
print_r($test->testField);
echo "<br />";

$test->set('a', 'A');
$test->set('b', 'B');

echo "After Setting: ";
print_r($test->testField);

class BugTest {
	var $field = "testField";
	
	function BugTest() {
		$this->{$this->field} = array();
	}
	
	function set($key, $value) {
		$this->{$this->field}[$key] = $value;
	}
}

?>