used forward declared struct instead of casting