-
Notifications
You must be signed in to change notification settings - Fork 13.6k
Closed
Labels
A-codegenArea: Code generationArea: Code generationA-type-systemArea: Type systemArea: Type systemC-enhancementCategory: An issue proposing an enhancement or a PR with one.Category: An issue proposing an enhancement or a PR with one.
Milestone
Description
We have agreement that the syntax expr.m()
will always represent a method call (and never a call to the field expr.m
). This allows us to make a change to the compiler AST so that we have expr_mcall()
(method call) and not expr_call(expr_field())
, which in turn allows various other simplifications in borrowck, trans, and elsewhere. In the process---or, perhaps, as first steps---I want to do some smaller refactorings:
- Represent vtables as a tree and not the current flattened representation. This will simplify code all over the place.
- Remove the
callee_id
and just hang method information off in different tables (this basically requires an expr_mcall) - Maybe: change how operator overloading is implemented so that, from the front end's point of view, all overloadable operations are method calls, but some of them call "intrinsic" methods. Constant expressions are therefore restricted to such intrinsics, and of course trans will generate
a+b
the same way it does today.
Metadata
Metadata
Assignees
Labels
A-codegenArea: Code generationArea: Code generationA-type-systemArea: Type systemArea: Type systemC-enhancementCategory: An issue proposing an enhancement or a PR with one.Category: An issue proposing an enhancement or a PR with one.