mirror of
https://github.com/erg-lang/erg.git
synced 2025-08-04 10:49:54 +00:00
perf: reduce performing of .loc()
This commit is contained in:
parent
5d90029f09
commit
5f6c8a3b2b
9 changed files with 83 additions and 49 deletions
|
@ -1390,11 +1390,7 @@ impl HasType for Call {
|
|||
}
|
||||
}
|
||||
|
||||
impl Locational for Call {
|
||||
fn loc(&self) -> Location {
|
||||
Location::concat(self.obj.as_ref(), &self.args)
|
||||
}
|
||||
}
|
||||
impl_locational!(Call, obj, args);
|
||||
|
||||
impl Call {
|
||||
pub fn new(obj: Expr, attr_name: Option<Identifier>, args: Args) -> Self {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue