Sorry again for the buggy minimal example. Please try again with the attached version. Instructions as before: 1. Evaluate the elisp code contained in the section "Code to evaluate", either by executing =(org-babel-load-file buffer-file-name)=, or by evaluating manually each function using =C-x C-e= 2. Run the small tests contained in the section "Transclusion tests" using =(org-babel-execute-buffer)=. This will behave as expected 3. Restore the buffer to its original contents using =C-_= 4. Now, run =(org-babel-exp-non-block-elements (point-min) (point-max))= and compare with the behaviour in step (2.)