<cfscript>

	data = {};

	echoVersion();
	// Normally we think of the compare() and compareNoCase() functions as testing String
	// values. But, it seems that these functions appear to play nicely with NULL values
	// as well. Which means, we can use them with the SAFE-NAVIGATION operator and not
	// have to worry about performing NULL coalescing to avoid errors!
	echoValue( compare( data?.foo, "bar" ) );
	echoValue( compare( "foo", data?.bar ) );
	echoValue( compare( data?.foo, data?.bar ) );
	echoValue( compare( javaCast( "null", "" ), javaCast( "null", "" ) ) );

	// ------------------------------------------------------------------------------- //
	// ------------------------------------------------------------------------------- //

	// I output the current ColdFusion product version.
	public void function echoVersion() {

		var version = ( server.keyExists( "lucee" ) )
			? "Lucee CFML #server.lucee.version#"
			: "Adobe ColdFusion #server.coldfusion.productVersion#"
		;

		writeOutput( version & "<br /><br />" );

	}


	// I output the given value on its own line.
	public void function echoValue( required any value ) {

		writeOutput( value & "<br />" );

	}

</cfscript>