fixed bug occurring when a line contains both a valid directive and a comment