Effects of heterogeneity on diffusion in nanopores—From inorganic materials to protein crystals and ion channels