I feel like the three terms are often used as synonyms but actually all mean something different. I did look at Wikipedia sites and at a related question but I'm still unsure about the definitions of the three.
From my understanding, routing is concerned about finding a path to a destination and deciding where to send a (unknown) packet based on its destination or prefix and not just based on a simple lookup in a table. This is what happens at IP routers (shortest prefix routing).
These simple lookups are what I understand as forwarding: The header/label (cf. MPLS)/etc are matched against entries in a flow table (or multiple tables). An exact match tells the switch at which port to output the packet without further computation. If no match is found, a default action is performed or a seperate controller is asked (as in SDN).
Switching seems to be fairly similar to forwarding but with an emphasis on what happens on hardware in the switching fabric after the lookup in a table. This on OSI level 2 (data link) while routing and forwarding are actions on level 3 (network)?
What's correct/wrong about these intuitions? Did I miss something of importance? Are there differences between IP routing/forwarding (Google returns the same Wikipedia article)? What about the MAC layer?