+#define var_CountChoices(a,b) var_CountChoices( VLC_OBJECT(a),b)
+
+
+static inline bool var_ToggleBool( vlc_object_t *p_obj, const char *psz_name )
+{
+ vlc_value_t val;
+ var_GetAndSet( p_obj, psz_name, VLC_VAR_BOOL_TOGGLE, &val );
+ return val.b_bool;
+}
+#define var_ToggleBool(a,b) var_ToggleBool( VLC_OBJECT(a),b )
+
+
+LIBVLC_USED
+static inline bool var_InheritBool( vlc_object_t *obj, const char *name )
+{
+ vlc_value_t val;
+
+ if( var_Inherit( obj, name, VLC_VAR_BOOL, &val ) )
+ val.b_bool = false;
+ return val.b_bool;
+}
+#define var_InheritBool(o, n) var_InheritBool(VLC_OBJECT(o), n)
+
+LIBVLC_USED
+static inline int64_t var_InheritInteger( vlc_object_t *obj, const char *name )
+{
+ vlc_value_t val;
+
+ if( var_Inherit( obj, name, VLC_VAR_INTEGER, &val ) )
+ val.i_int = 0;
+ return val.i_int;
+}
+#define var_InheritInteger(o, n) var_InheritInteger(VLC_OBJECT(o), n)
+
+LIBVLC_USED
+static inline float var_InheritFloat( vlc_object_t *obj, const char *name )
+{
+ vlc_value_t val;
+
+ if( var_Inherit( obj, name, VLC_VAR_FLOAT, &val ) )
+ val.f_float = 0.;
+ return val.f_float;
+}
+#define var_InheritFloat(o, n) var_InheritFloat(VLC_OBJECT(o), n)
+
+LIBVLC_USED LIBVLC_MALLOC
+static inline char *var_InheritString( vlc_object_t *obj, const char *name )
+{
+ vlc_value_t val;
+
+ if( var_Inherit( obj, name, VLC_VAR_STRING, &val ) )
+ val.psz_string = NULL;
+ else if( val.psz_string && !*val.psz_string )
+ {
+ free( val.psz_string );
+ val.psz_string = NULL;
+ }
+ return val.psz_string;
+}
+#define var_InheritString(o, n) var_InheritString(VLC_OBJECT(o), n)
+
+LIBVLC_USED
+static inline mtime_t var_InheritTime( vlc_object_t *obj, const char *name )
+{
+ vlc_value_t val;
+
+ if( var_Inherit( obj, name, VLC_VAR_TIME, &val ) )
+ val.i_time = 0;
+ return val.i_time;
+}
+#define var_InheritTime(o, n) var_InheritTime(VLC_OBJECT(o), n)
+
+LIBVLC_USED
+static inline void *var_InheritAddress( vlc_object_t *obj, const char *name )
+{
+ vlc_value_t val;
+
+ if( var_Inherit( obj, name, VLC_VAR_ADDRESS, &val ) )
+ val.p_address = NULL;
+ return val.p_address;
+}
+#define var_InheritAddress(o, n) var_InheritAddress(VLC_OBJECT(o), n)
+
+VLC_EXPORT( int, var_InheritURational, ( vlc_object_t *, unsigned *num, unsigned *den, const char *var ) );
+#define var_InheritURational(a,b,c,d) var_InheritURational(VLC_OBJECT(a), b, c, d)
+
+#define var_GetInteger(a,b) var_GetInteger( VLC_OBJECT(a),b)
+#define var_GetBool(a,b) var_GetBool( VLC_OBJECT(a),b)
+#define var_GetTime(a,b) var_GetTime( VLC_OBJECT(a),b)
+#define var_GetFloat(a,b) var_GetFloat( VLC_OBJECT(a),b)
+#define var_GetString(a,b) var_GetString( VLC_OBJECT(a),b)
+#define var_GetNonEmptyString(a,b) var_GetNonEmptyString( VLC_OBJECT(a),b)
+#define var_GetAddress(a,b) var_GetAddress( VLC_OBJECT(a),b)