octave-maintainers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: undefined compound chaining behavior


From: Hossein Sajjadi
Subject: Re: undefined compound chaining behavior
Date: Wed, 11 Jun 2014 23:33:36 +0330

To  show that undefined behavior is propagated from c++ through Octave
,it is sufficient to prove that the compound operator that is used in
Octave is actually the operator that is used in C++.
with syntax of bison parser if we write:
| VAR ADD_EQ exp { $1->value.var += $3; $$ = $1->value.var;     }
or the same thing such as :
double op_add_eq ( double& lhs,double rhs){
lhs=lhs+rhs;
return lhs;
}

there is no difference , and operator in two languages is the same,so
chaining compound assingnment results in undefined behavior in Octave



reply via email to

[Prev in Thread] Current Thread [Next in Thread]