Skip to content
This repository has been archived by the owner on Mar 19, 2021. It is now read-only.

Commit

Permalink
Merge pull request #15 from matasar/dont_error_if_first_line_at
Browse files Browse the repository at this point in the history
Don't panic if the first expression is @
  • Loading branch information
alfredxing committed Mar 11, 2016
2 parents 1a308a3 + 395d17c commit 1b54959
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion compute/compute.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ ScanLoop:
for {
_, tok, lit := s.Scan()

if lit != "@" && back > -1 {
if lit != "@" && back > -1 && len(resHistory) > 0 {
floats.Push(getHistory(back))
if prev == token.RPAREN || constants.IsConstant(prev.String()) {
evalUnprecedenced("*", ops, floats)
Expand Down

0 comments on commit 1b54959

Please sign in to comment.