Narrowing and query-replace