ref: store the target in the record

There's no need to create a new object every time the user asks for
the target, so store it the same way we do for the type.
This commit is contained in:
Carlos Martín Nieto
2013-05-02 03:53:07 +02:00
parent 0127730f6b
commit 9d7139d604
2 changed files with 11 additions and 7 deletions

View File

@@ -1,4 +1,4 @@
-record(ref, {handle, type :: atom()}).
-record(ref, {handle, type :: atom(), target :: binary() | oid()}).
-record(repo, {handle}).
-record(odb, {handle}).
-record(revwalk, {handle}).