more robust parsing of directive arguments (see #322)
rebuilt