[Fix #1001] Fix --auto-gen-config logic for RegexpLiteral

A lot of different cases to consider, so more spec examples added.