Re: Is this OK in C++ and C?
On Tuesday 01 of January 2013 08:23:05 you wrote:
> C lessons today? (There are newsgroups for C and C++ questions, but, why not?)
Yes :-)
I wanted to prohibit user to assign negative value to a variable.
This variable is later passed to a recurrence function as
argument and of course I got segmentation fault, because
the function is called 4294967291 times.
I was very surprised when I discover that this code was compiled
without any warning. I thought if a variable is 'unsigned int'
then this is not allowed to assign negative value.
That's all.
Thank you very much.
> --
> Joel Rees
>
Reply to: