# as a word is not used by groups, so it would not interfere with that. Groups use lines like

#groupname on
code
#groupname end

... so the # as a separate word only is used as an alias for $chan, and since that should not be used as the first 'word' of a script line, it shouldn't interfere with that either.