Return environment value for the symbol.

If there is no such environment variable, then return ""

assert "PATH".environ     != ""
assert "NIT %\n".environ  == ""

Property definitions

core :: environ $ String :: environ
	# Return environment value for the symbol.
	# If there is no such environment variable, then return ""
	#
	#     assert "PATH".environ     != ""
	#     assert "NIT %\n".environ  == ""
	fun environ: String
	do
		var res = self.to_cstring.get_environ
		# FIXME: There is no proper way to handle NULL C string yet. What a pitty.
		var nulstr = once ("".to_cstring.get_environ)
		if res != nulstr then
			return res.to_s
		else
			return ""
		end
	end
lib/core/environ.nit:23,2--38,4