<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def predict_type(self):
 """ Predict the type of the inst_ref, and make sure the property being referenced is allowed """

        inst_type = self.inst_ref.predict_type()

        if self.prop_ref_type.allowed_inst_type != inst_type:
            self.msg.fatal(
                "'%s' is not a valid property of instance" % self.prop_ref_type.get_name(),
                self.src_ref
            )

        return self.prop_ref_type