vendor/gems/BlueCloth-1.0.0/lib/bluecloth.rb
### Return a copy of the given +str+ with any backslashed special character
### in it replaced with MD5 placeholders.
Return a copy of the given +str+ with any backslashed special character
in it replaced with MD5 placeholders.
Return a copy of the given + str + with any backslashed special character in it replaced with MD5 placeholders .
def encode_backslash_escapes( str )
		text = str.gsub( /\\\\/, EscapeTable['\\'][:md5] )
		EscapeTable.each_pair {|char, esc|
			next if char == '\\'
			text.gsub!( esc[:re], esc[:md5] )
		}
		return text
	end
def encode_backslash_escapes ( str ) text = str . gsub ( / \\ \\ / , EscapeTable [ '\\' ] [ :md5 ] ) EscapeTable . each_pair { | char , esc | next if char == '\\' text . gsub! ( esc [ :re ] , esc [ :md5 ] ) } return text end
Return a copy of the given +str+ with any backslashed special character
in it replaced with MD5 placeholders.
Return a copy of the given + str + with any backslashed special character in it replaced with MD5 placeholders .
# Make a copy with any double-escaped backslashes encoded
str
<not_specific>