-
Type: Bug
-
Resolution: Won't Fix
-
Priority: Major - P3
-
None
-
Affects Version/s: 1.6.5
-
Component/s: JavaScript
-
None
-
Environment:osx x86_64 - mongodb 1.6.5
-
ALL
Hi,
I just want to use the map reduce function of MongoDB. So I wrote a simple map_index function in javascript :
function map_index()
{
var _translit = [
[/ä|æ/g, 'ae'],
];
...
...
...
After that, I try to load the file (index.js) into Mongo Shell and :
> load('index.js');
map reduce failed: {
"assertion" : "map compile failed: JS Error: SyntaxError: unterminated regular expression literal nofile_b:1",
"assertionCode" : 9012,
"errmsg" : "db assertion failure",
"ok" : 0
}
There is no problem if I remove "| æ".
var _translit = [
[/ä/g, 'ae'],
];
The same behavior when I remove "ä" and keep "æ".
Of course, the file is encoded in utf-8. Full test code can be found as Attachment.
- depends on
-
SERVER-2407 Switch to v8
- Closed