If you are allergic to walnut trees, does that mean you should not eat walnuts?

No. The allergens in the food and in the pollen are different. Just like pecan tree and pecan nut, you should be fine because of that reason. Talk to your allergist if you have any questions.