http: remove MethodToString()
authorBen Noordhuis <info@bnoordhuis.nl>
Mon, 28 Oct 2013 12:44:41 +0000 (13:44 +0100)
committerBen Noordhuis <info@bnoordhuis.nl>
Mon, 28 Oct 2013 12:57:22 +0000 (13:57 +0100)
commit4c0195e0340220e53fe5c44299eff53f2f0e210c
tree1657763ab4333e63e2798e1de5e0afd247a14385
parent610022851aaeff7a96518a8ee04826547dc33969
http: remove MethodToString()

The list of supported HTTP methods is available in JS land now so there
is no longer any need to pass a stringified version of the method to the
parser callback, it can look up the method name for itself.

Saves a call to v8::Eternal::Get() in the common case and a costly
v8::String::NewFromOneByte() in the uncommon case.
lib/_http_common.js
src/env.h
src/node_http_parser.cc
test/simple/test-http-parser.js