/*
 * Function name: check_adverb_with_space
 * Defined in   : /cmd/std/command_driver.c
 * Description  : This function returns the adverb from check_adverb with a
 *                preceding space if it is an adverb and it returns an empty
 *                string if the adverb was the special adverb that means that
 *                the player does not want an adverb.
 * Arguments    : str     - the pattern to match
 *                def_adv - the default adverb
 * Returns      : string  - the full adverb or NO_ADVERB_WITH_SPACE
 *
 * The capitalized macros are defined in /sys/adverbs.h
 *
 * NO_ADVERB_WITH_SPACE is returned if a false adverb is passed to this
 * function. If the passed pattern str has only one or two characters, it is
 * considered to be a failed match.
 *
 * If the string "." is passed to the function as an adverb the player
 * explicitly specifies that he doesn't want to use an adverb, BLANK_ADVERB
 * is returned. You can use BLANK_ADVERB as a default adverb.
 *
 * NO_DEFAULT_ADVERB can be used as a default adverb if you want to select
 * a default adverb after the parse has been made, for instance if you want
 * to use a different default adverb for the emote with or without a target.
 * Then after you checked whether the emote should be on a target or not,
 * you can check for NO_DEFAULT_ADVERB_WITH_SPACE and if so, replace it
 * with a default.
 *
 * Examples:
 *
 * str,       def_adv   -> returns
 *
 * "happ",    "merrily" -> " happily"
 * "happily", "merrily" -> " happily"
 * "ha",      "merrily" -> " merrily"
 * "merr",    "merrily" -> " merrily"
 * "mrpr",    "merrily" -> NO_ADVERB_WITH_SPACE
 * "",        "merrily" -> " merrily"
 * ".",       "merrily" -> ""
 */
string
check_adverb_with_space(string str, string def_adv)
