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

Implementation of IMPORT #868

Merged
merged 8 commits into from
Mar 18, 2021
Merged

Implementation of IMPORT #868

merged 8 commits into from
Mar 18, 2021

Conversation

vladaionescu
Copy link
Member

@vladaionescu vladaionescu commented Mar 17, 2021

Re #581

Syntax is:

IMPORT github.com/foo/bar:v1.2.3
IMPORT github.com/foo/buz:main AS zulu

...

FROM bar+target
BUILD zulu+something

@vladaionescu vladaionescu marked this pull request as ready for review March 18, 2021 03:36
@@ -166,6 +174,11 @@ func (c *Collection) ExitFrame() {
c.effectiveCache = nil
}

// IsStackAtBase returns whether the stack has size 1.
func (c *Collection) IsStackAtBase() bool {
return len(c.stack) == 1
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: should we check for a condition like

if len(c.stack) == 0 { panic("shouldnt happen") }

then again if it's empty that might cause some nil exceptions elsewhere. 🤷

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes - we actually have such a check in popStackFrame

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants