/* valafloatingtype.c generated by valac, the Vala compiler
 * generated from valafloatingtype.vala, do not modify */

/* valafloatingtype.vala
 *
 * Copyright (C) 2009  Jürg Billeter
 *
 * This library is free software; you can redistribute it and/or
 * modify it under the terms of the GNU Lesser General Public
 * License as published by the Free Software Foundation; either
 * version 2.1 of the License, or (at your option) any later version.

 * This library is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 * Lesser General Public License for more details.

 * You should have received a copy of the GNU Lesser General Public
 * License along with this library; if not, write to the Free Software
 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301  USA
 *
 * Author:
 * 	Jürg Billeter <j@bitron.ch>
 */

#include <glib.h>
#include <glib-object.h>
#include "vala.h"

#define _vala_code_node_unref0(var) ((var == NULL) ? NULL : (var = (vala_code_node_unref (var), NULL)))


static gpointer vala_floating_type_parent_class = NULL;

static ValaDataType* vala_floating_type_real_copy (ValaDataType* base);


ValaFloatingType* vala_floating_type_construct (GType object_type, ValaStruct* type_symbol) {
	ValaFloatingType* self = NULL;
	ValaStruct* _tmp0_;
	g_return_val_if_fail (type_symbol != NULL, NULL);
	_tmp0_ = type_symbol;
	self = (ValaFloatingType*) vala_value_type_construct (object_type, (ValaTypeSymbol*) _tmp0_);
	return self;
}


ValaFloatingType* vala_floating_type_new (ValaStruct* type_symbol) {
	return vala_floating_type_construct (VALA_TYPE_FLOATING_TYPE, type_symbol);
}


static ValaDataType* vala_floating_type_real_copy (ValaDataType* base) {
	ValaFloatingType * self;
	ValaDataType* result = NULL;
	ValaFloatingType* _result_ = NULL;
	ValaTypeSymbol* _tmp0_;
	ValaTypeSymbol* _tmp1_;
	ValaFloatingType* _tmp2_;
	ValaSourceReference* _tmp3_;
	ValaSourceReference* _tmp4_;
	gboolean _tmp5_;
	gboolean _tmp6_;
	gboolean _tmp7_;
	gboolean _tmp8_;
	self = (ValaFloatingType*) base;
	_tmp0_ = vala_value_type_get_type_symbol ((ValaValueType*) self);
	_tmp1_ = _tmp0_;
	_tmp2_ = vala_floating_type_new (G_TYPE_CHECK_INSTANCE_CAST (_tmp1_, VALA_TYPE_STRUCT, ValaStruct));
	_result_ = _tmp2_;
	_tmp3_ = vala_code_node_get_source_reference ((ValaCodeNode*) self);
	_tmp4_ = _tmp3_;
	vala_code_node_set_source_reference ((ValaCodeNode*) _result_, _tmp4_);
	_tmp5_ = vala_data_type_get_value_owned ((ValaDataType*) self);
	_tmp6_ = _tmp5_;
	vala_data_type_set_value_owned ((ValaDataType*) _result_, _tmp6_);
	_tmp7_ = vala_data_type_get_nullable ((ValaDataType*) self);
	_tmp8_ = _tmp7_;
	vala_data_type_set_nullable ((ValaDataType*) _result_, _tmp8_);
	result = (ValaDataType*) _result_;
	return result;
}


static void vala_floating_type_class_init (ValaFloatingTypeClass * klass) {
	vala_floating_type_parent_class = g_type_class_peek_parent (klass);
	((ValaDataTypeClass *) klass)->copy = (ValaDataType* (*) (ValaDataType *)) vala_floating_type_real_copy;
}


static void vala_floating_type_instance_init (ValaFloatingType * self) {
}


/**
 * A floating-point type.
 */
GType vala_floating_type_get_type (void) {
	static volatile gsize vala_floating_type_type_id__volatile = 0;
	if (g_once_init_enter (&vala_floating_type_type_id__volatile)) {
		static const GTypeInfo g_define_type_info = { sizeof (ValaFloatingTypeClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) vala_floating_type_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (ValaFloatingType), 0, (GInstanceInitFunc) vala_floating_type_instance_init, NULL };
		GType vala_floating_type_type_id;
		vala_floating_type_type_id = g_type_register_static (VALA_TYPE_VALUE_TYPE, "ValaFloatingType", &g_define_type_info, 0);
		g_once_init_leave (&vala_floating_type_type_id__volatile, vala_floating_type_type_id);
	}
	return vala_floating_type_type_id__volatile;
}



