Can now handle when the cursor is not within a function