Skip to content

Commit

Permalink
Merge pull request #1133 from wavesplatform/NODE-737-no-get-kyewords-…
Browse files Browse the repository at this point in the history
…identificator

Do not use any keywords as identificator.
  • Loading branch information
ismagin authored May 28, 2018
2 parents fce7a50 + 00025de commit 6d6a824
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
package com.wavesplatform.lang.v1.testing

import com.wavesplatform.lang.v1.parser.Parser.keywords
import com.wavesplatform.lang.v1.parser.BinaryOperation
import com.wavesplatform.lang.v1.parser.BinaryOperation._
import com.wavesplatform.lang.v1.parser.Expressions._
Expand Down Expand Up @@ -104,7 +105,7 @@ trait ScriptGen {
} yield LET(0, 0, PART.VALID(0, 0, name), value, Seq.empty)

def REFgen: Gen[EXPR] =
Gen.identifier.map(PART.VALID[String](0, 0, _)).map(REF(0, 0, _))
Gen.identifier.filter(!keywords(_)).map(PART.VALID[String](0, 0, _)).map(REF(0, 0, _))

def BLOCKgen(gas: Int): Gen[EXPR] =
for {
Expand Down

0 comments on commit 6d6a824

Please sign in to comment.