aboutsummaryrefslogtreecommitdiffstats
path: root/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/namecoin.se
diff options
context:
space:
mode:
Diffstat (limited to 'Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/namecoin.se')
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/namecoin.se7
1 files changed, 7 insertions, 0 deletions
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/namecoin.se b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/namecoin.se
new file mode 100644
index 000000000..11d6274ae
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/namecoin.se
@@ -0,0 +1,7 @@
+def register(k, v):
+ if !self.storage[k]: # Is the key not yet taken?
+ # Then take it!
+ self.storage[k] = v
+ return(1)
+ else:
+ return(0) // Otherwise do nothing