add exit to primitive