(s)
return s.replace("#", r"\#")
Escapes a CPP define so that it will reach the compiler unaltered.
Escapes a CPP define so that it will reach the compiler unaltered.
Escapes a CPP define so that it will reach the compiler unaltered .
def EscapeCppDefine(s):
    """Escapes a CPP define so that it will reach the compiler unaltered."""
    s = EscapeShellArgument(s)
    s = EscapeMakeVariableExpansion(s)
    # '#' characters must be escaped even embedded in a string, else Make will
    # treat it as the start of a comment.
    return s.replace("#", r"\#")
def EscapeCppDefine ( s ) : s = EscapeShellArgument ( s ) s = EscapeMakeVariableExpansion ( s ) # '#' characters must be escaped even embedded in a string, else Make will # treat it as the start of a comment. return s . replace ( "#" , r"\#" )