def trim_hash_from_symbol(symbol):
    """If the passed symbol ends with a hash of the form h[16-hex number]
       trim this and return the trimmed symbol."""
     # Remove the hash off the end
    tokens = symbol.split('::')
    last = tokens[-1]
    if last[0] == 'h':
        tokens = tokens[:-1] # Trim off hash if it exists
        trimmed_name = "::".join(tokens) # reassemble
        return trimmed_name
    else:
        return symbol