Scanner extended to deal with Terminal array, fill, .., [ and ].