| Age | Commit message (Collapse) | Author | Lines |
|
|
|
All the files below had at least one instance of the ternary operator
present in the source. All have been changed to the equivalent
if/then/else expression.
|
|
When no built-in interpretation is found for one of the operators
mentioned below, the typechecker will try to turn it into a method
call with the name written next to it. For binary operators, the
method will be called on the LHS with the RHS as only parameter.
Binary:
+ op_add
- op_sub
* op_mul
/ op_div
% op_rem
& op_and
| op_or
^ op_xor
<< op_shift_left
>> op_shift_right
>>> op_ashift_right
Unary:
- op_neg
! op_not
Overloading of the indexing ([]) operator isn't finished yet.
Issue #1520
|
|
This should reduce confusion of people trying to read the code.
|
|
Does what it says on the tin.
The next commit will remove support for this syntax.
|
|
Remove disr_val from ast::variant_ and always use ty::variant_info
when the value is needed. Move what was done during parsing into
other passes, primary typeck.rs. This move also correctly type checks
the disr. value expression; thus, fixing rustc --pretty=typed when
disr. values are used.
|
|
Rather, it is now a struct where properties like opts are accessed
directly, and the error-reporting methods are part of a static impl
(with the same name as the type).
|
|
I consider the added complexity not justified at this point, and it
interacts badly with the patches for issue #828. Feel free to discuss.
|
|
|
|
Part of #1215
|
|
This removes the need for the unary minus hacks, and allows some other
neat things like matching on 1 >> 4.
Issue #954
|
|
|
|
|
|
trans_const_expr. Working towards issue #570.
|
|
rejects unimplemented const expressions, but will be needed later.
|