Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Subscript Operator #92

Merged
merged 32 commits into from
May 15, 2019
Merged

Subscript Operator #92

merged 32 commits into from
May 15, 2019

Conversation

rdtscp
Copy link
Owner

@rdtscp rdtscp commented May 10, 2019

No description provided.

@rdtscp rdtscp added the enhancement New feature or request label May 10, 2019
@rdtscp rdtscp self-assigned this May 10, 2019
@rdtscp rdtscp changed the title Subscript Operator WIP Subscript Operator May 11, 2019
@rdtscp
Copy link
Owner Author

rdtscp commented May 11, 2019

Conflict between SubscriptOp and ArrayAccess. Merge both into SubscriptOp and do more work in SemanticAnalysis.

@rdtscp
Copy link
Owner Author

rdtscp commented May 11, 2019

Scopes should have some method of finding operator overloads/definitions, so that SubscriptOp can resolve the operation during SemanticAnalaysis

@rdtscp
Copy link
Owner Author

rdtscp commented May 14, 2019

With the refactor to make Scope a virtual abstract class, now we must do namespace resolution when we reference an identifier under a namespace.

@todo
Copy link

todo bot commented May 14, 2019

Initialise this FunDef with an implementation.

// TODO: Initialise this FunDef with an implementation.
const atl::shared_ptr<FunDef> arrayPointerSubscriptOpDef;
so.operatorDecl = arrayPointerSubscriptOpDef;
return atl::static_pointer_cast<PointerType>(objType)->pointedType;
} else if (objType->astClass() == "ClassType") {
const atl::shared_ptr<ClassType> objClassType =


This comment was generated by todo based on a TODO comment in b2d3373 in #92. cc @rdtscp.

@todo
Copy link

todo bot commented May 14, 2019

Incorporate return type?

// TODO: Incorporate return type?
// Check args match.
for (int idx = 0; idx < funArgs.size(); ++idx)
if (*funArgs[idx] != *rhs.funArgs[idx])
return false;


This comment was generated by todo based on a TODO comment in 287dbbb in #92. cc @rdtscp.

@todo
Copy link

todo bot commented May 14, 2019

~Create: Type preventCascade(const Type t);

// TODO: ~Create: Type preventCascade(const Type t);
};
} // namespace ACC


This comment was generated by todo based on a TODO comment in 287dbbb in #92. cc @rdtscp.

@todo
Copy link

todo bot commented May 14, 2019

Create FunSignature for SubscriptOp.

// TODO: Create FunSignature for SubscriptOp.
// const atl::string operatorSignature =
// objClassType->getSignature() + "::operator[](" +
// objClassType->getSignature() + "*, " + indexType->getSignature() +
// ")";
// const atl::shared_ptr<FunDecl> objSubscriptOpDecl =


This comment was generated by todo based on a TODO comment in 287dbbb in #92. cc @rdtscp.

@rdtscp
Copy link
Owner Author

rdtscp commented May 14, 2019

#83 Appears to have been resolved here.

@rdtscp rdtscp changed the title WIP Subscript Operator Subscript Operator May 15, 2019
@rdtscp rdtscp changed the title Subscript Operator Subscript Operator May 15, 2019
@rdtscp rdtscp merged commit dd61497 into master May 15, 2019
@rdtscp rdtscp deleted the Operator-AT branch May 15, 2019 22:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant