diff --git a/global.go b/global.go
index <HASH>..<HASH> 100644
--- a/global.go
+++ b/global.go
@@ -736,7 +736,7 @@ func (runtime *_runtime) newNodeFunction(node *_functionNode, scopeEnvironment _
 	self := runtime.newNodeFunctionObject(node, scopeEnvironment)
 	self.Prototype = runtime.Global.FunctionPrototype
 	prototype := runtime.newObject()
-	self.define(_propertyMode(0), "prototype", toValue(prototype))
+	self.define(_propertyMode(propertyModeWrite), "prototype", toValue(prototype))
 	prototype.define(
 		_propertyMode(propertyModeWrite | propertyModeConfigure),
 		"constructor", toValue(self),
diff --git a/otto_test.go b/otto_test.go
index <HASH>..<HASH> 100644
--- a/otto_test.go
+++ b/otto_test.go
@@ -1501,6 +1501,19 @@ func TestNewFunction(t *testing.T) {
 	`, "13")
 }
 
+func TestNewPrototype(t *testing.T) {
+	Terst(t)
+
+	test := runTest()
+
+	test(`
+		abc = { 'xyzzy': 'Nothing happens.' }
+		function Xyzzy(){}
+		Xyzzy.prototype = abc;
+		(new Xyzzy()).xyzzy
+	`, "Nothing happens.")
+}
+
 func TestWith(t *testing.T) {
 	Terst(t)
Fix prototype property being read-only

Fix #3