Is it bad coding style?
Hi,
I'm browsing thru some code and it contains a pile of "tmp" named vars of different types.
Have a look, is it a good coding style? Any good reason to use that many "tmp" (non mnemonic) names?
Just wondering.
PHP Code:
static gboolean main_window_change_background_timeout_cb (MainWindow* self) {
gboolean result = FALSE;
gchar* new_background_file = NULL;
gboolean _tmp0_ = FALSE;
MenuBar* _tmp1_;
gboolean _tmp2_;
gboolean _tmp3_;
gboolean _tmp5_;
Background* _tmp11_;
const gchar* _tmp12_;
g_return_val_if_fail (self != NULL, FALSE);
_tmp1_ = self->priv->menubar;
_tmp2_ = menu_bar_get_high_contrast (_tmp1_);
_tmp3_ = _tmp2_;
if (_tmp3_) {
_tmp0_ = TRUE;
} else {
gboolean _tmp4_ = FALSE;
_tmp4_ = ug_settings_get_boolean (UG_SETTINGS_KEY_DRAW_USER_BACKGROUNDS);
_tmp0_ = !_tmp4_;
}
_tmp5_ = _tmp0_;
if (_tmp5_) {
_g_free0 (new_background_file);
new_background_file = NULL;
} else {
UserList* _tmp6_;
UserEntry* _tmp7_;
UserEntry* _tmp8_;
const gchar* _tmp9_;
gchar* _tmp10_;
_tmp6_ = self->user_list;
_tmp7_ = user_list_get_selected_entry (_tmp6_);
_tmp8_ = _tmp7_;
_tmp9_ = _tmp8_->background;
_tmp10_ = g_strdup (_tmp9_);
_g_free0 (new_background_file);
new_background_file = _tmp10_;
}
_tmp11_ = self->priv->background;
_tmp12_ = new_background_file;
background_set_current_background (_tmp11_, _tmp12_);
self->priv->change_background_timeout = (guint) 0;
result = FALSE;
_g_free0 (new_background_file);
return result;
}
Your ads here, just 9.99$/week !!
Bookmarks