couchdb-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From fdman...@apache.org
Subject svn commit: r1002563 - /couchdb/branches/new_replicator/src/couchdb/couch_db.hrl
Date Wed, 29 Sep 2010 10:16:16 GMT
Author: fdmanana
Date: Wed Sep 29 10:16:16 2010
New Revision: 1002563

URL: http://svn.apache.org/viewvc?rev=1002563&view=rev
Log:
Mergging revision 1001863 from trunk:

Adding new macro ?getv as an alias to couch_util:get_value.
That function is used so often by most (if not all) modules that it deserves
a small macro to help keeping the code short.


Modified:
    couchdb/branches/new_replicator/src/couchdb/couch_db.hrl

Modified: couchdb/branches/new_replicator/src/couchdb/couch_db.hrl
URL: http://svn.apache.org/viewvc/couchdb/branches/new_replicator/src/couchdb/couch_db.hrl?rev=1002563&r1=1002562&r2=1002563&view=diff
==============================================================================
--- couchdb/branches/new_replicator/src/couchdb/couch_db.hrl (original)
+++ couchdb/branches/new_replicator/src/couchdb/couch_db.hrl Wed Sep 29 10:16:16 2010
@@ -25,6 +25,9 @@
 -define(l2b(V), list_to_binary(V)).
 -define(l2i(V), list_to_integer(V)).
 
+-define(getv(Key, List), couch_util:get_value(Key, List)).
+-define(getv(Key, List, Default), couch_util:get_value(Key, List, Default)).
+
 -define(DEFAULT_ATTACHMENT_CONTENT_TYPE, <<"application/octet-stream">>).
 
 -define(LOG_DEBUG(Format, Args),



Mime
View raw message