Trying to write a little script that uses eval like this:

eval("\\$$key = \\"$value\\"");

This doesn't work and below is the error. Any help please?

Scalar found where operator expected at samp.pl line 17, near ""\\$$key = \\"$value"
(Missing operator before $value?)
Backslash found where operator expected at samp.pl line 17, near "$value\"
(Missing operator before \?)
syntax error at samp.pl line 17, near ""\\$$key = \\"$value"
Execution of samp.pl aborted due to compilation errors.