docs: function _clone(thing){
  
      var clone = null;
      
      if( typeof(thing) === 'undefined' ){
  	// Nothin' doin'.
  	//print("looks undefined");
      }else if( typeof(thing) === 'function' ){
  	// Dunno about this case...
  	//print("looks like a function");
  	clone = thing;
      }else if( typeof(thing) === 'boolean' ||
  	      typeof(thing) === 'number' ||
  	      typeof(thing) === 'string' ){
  		  // Atomic types can be returned as-is (i.e. assignment in
  		  // JS is the same as copy for atomic types).
  		  //print("cloning atom: " + thing);
  		  clone = thing;
  	      }else if( typeof(thing) === 'object' ){
  		  // Is it a null, hash, or an array?
  		  if( thing == null ){
  		      clone = null;
  		  }else if( Array.isArray(thing) ){
  		      // Looks like an array!
  		      //print("looks like an array");
  		      clone = [];
  		      for(var i = 0; i < thing.length; i++){
  			  clone[i] = _clone(thing[i]);
  		      }
  		  }else{
  		      // Looks like a hash!
  		      //print("looks like a hash");
  		      clone = {};
  		      for(var h in thing){
  			  clone[h] = _clone(thing[h]);
  		      }
  		  }
  	      }else{
  		  // Then I don't know what it is--might be platform dep.
  		  //print("no idea what it is");
  	      }
      return clone;
  }