Standard lattice calculations in flavour physics or in studies of hadronic structure are based on the evaluation of matrix elements of local composite operators between hadronic states or the vacuum. In this talk I discuss developments aimed at the computation of long-distance, and hence non-local, contributions to such processes. In particular, I consider the calculation of the $K_L$-$K_S$ mass difference $Delta m_K=m_{K_L}-m_{K_S}$ and the amplitude for the rare-kaon decay processes $Ktopiell^+ell^-$, where the lepton $ell=e$ or $mu$. Lattice calculations of the long-distance contributions to the indirect $CP$-violating parameter $epsilon_K$ and to the rare decays $Ktopi ubar u$ are also beginning. Finally I discuss the possibility of including $O(alpha)$ electromagnetic effects in computations of leptonic and semileptonic decay widths, where the novel feature is the presence of infrared divergences. This implies that contributions to the width from processes with a real photon in the final state must be combined with those with a virtual photon in the amplitude so that the infrared divergences cancel by the Bloch-Nordsieck mechanism. I present a proposed procedure for lattice computations of the $O(alpha)$ contributions with control of the cancellation of the infrared divergences.