Dear busybox developers,

May I ask some little code questions? I have been reading some of the
changes in busybox and I don't understand the use of type "smallint" in
this code

9a64c3337cc0a5e84e9ad457eeb1d475c311e9fc "ls: convert DISP_DIRNAME to
a bool variable"

ls.c

    @@ -330,7 +326,7 @@ struct globals {
     # define G_show_color 0
     #endif
      smallint exit_code;
    - unsigned all_fmt;
    + smallint show_dirname;
     #if ENABLE_FEATURE_LS_WIDTH
      unsigned terminal_width;
     # define G_terminal_width (G.terminal_width)

Here it seems that this "show_dirname" variable is supposed to hold a
boolean value, but why not declare it with the type bool? What's the
rationale behind preferring smallint?

Thank you.
Kang-Che Sung
_______________________________________________
busybox mailing list
[email protected]
http://lists.busybox.net/mailman/listinfo/busybox

Reply via email to