Shielded Reinforcement Learning for Hybrid Systems