Fix issue #1: literal content in rules being lost; also fixes issues with matched, contentless rules getting a valid node created.