Generalize `is` and make Cursor construction generic